bittensor.commands.misc
#
Module Contents#
Classes#
Show users how to install and run autocompletion for Bittensor CLI. |
|
Executes the |
Attributes#
- class bittensor.commands.misc.AutocompleteCommand#
Show users how to install and run autocompletion for Bittensor CLI.
- static add_args(parser)#
- static check_config(config)#
- static run(cli)#
- class bittensor.commands.misc.UpdateCommand#
Executes the
update
command to update the local Bittensor package.This command performs a series of operations to ensure that the user’s local Bittensor installation is updated to the latest version from the master branch of its GitHub repository. It primarily involves pulling the latest changes from the repository and reinstalling the package.
- Usage:
Upon invocation, the command first checks the user’s configuration for the
no_prompt
setting. Ifno_prompt
is set toTrue
, or if the user explicitly confirms withY
when prompted, the command proceeds to update the local Bittensor package. It changes the current directory to the Bittensor package directory, checks out the master branch of the Bittensor repository, pulls the latest changes, and then reinstalls the package usingpip
.
The command structure is as follows:
Change directory to the Bittensor package directory.
Check out the master branch of the Bittensor GitHub repository.
Pull the latest changes with the
--ff-only
option to ensure a fast-forward update.Reinstall the Bittensor package using pip.
Example usage:
btcli legacy update
Note
This command is intended to be used within the Bittensor CLI to facilitate easy updates of the Bittensor package. It should be used with caution as it directly affects the local installation of the package. It is recommended to ensure that any important data or configurations are backed up before running this command.
- static add_args(parser)#
- Parameters:
parser (argparse.ArgumentParser) –
- static check_config(config)#
- Parameters:
config (bittensor.config) –
- static run(cli)#
- bittensor.commands.misc.console#