bundles / IPython 9.17.0 / IPython / core / magic / MagicsManager / register_alias
function
IPython.core.magic:MagicsManager.register_alias
Signature
def register_alias(self, alias_name: str, magic_name: str, magic_kind: _MagicKind = line, magic_params: str | None = None) → NoneSummary
Register an alias to a magic function.
Extended Summary
The alias is an instance of MagicAlias, which holds the name and kind of the magic it should call. Binding is done at call time, so if the underlying magic function is changed the alias will call the new function.
Parameters
alias_name: strThe name of the magic to be registered.
magic_name: strThe name of an existing magic.
magic_kind: strKind of magic, one of 'line' or 'cell'
Aliases
IPython.core.magic.MagicsManager.register_alias