def change_func_def(self, original_node, updated_node) -> cst.FunctionDef:
        """
        Renames method definitions using the cmd_ prefix and adds the
        @expose_command decorator.

        Also sets a flag to show that the script should add the relevant
        import if it's missing.
        """
        decorator = cst.Decorator(cst.Name("expose_command"))
        name = original_node.name
        updated = name.with_changes(value=name.value[4:])

        self.lint(
            original_node,
            "Use of 'cmd_' prefix is deprecated. Use '@expose_command' when defining methods.",
        )

        self.needs_import = True

        return updated_node.with_changes(name=updated, decorators=[decorator])

        Renames method definitions using the cmd_ prefix and adds the
        @expose_command decorator.

        Also sets a flag to show that the script should add the relevant
        import if it's missing.
        
libqtile/scripts/migrations/remove_cmd_prefix.py