Package: launch-cli
Launch CLISimple CLI utility for common Launch tasks. This is intended to be built upon as new tasks are discovered.PrerequisitesPython 3.11+ and pipA GitHub accountGetting StartedTo use this tool, you will need to create a GitHub Personal Access Token (PAT) if you have not already done so. Ensure the PAT has sufficient permissions for your use case.More information on GitHub PATs can be foundhere.The PAT must be provided to this script through theGITHUB_TOKENenvironment variable. Alternate credential stores are not currently supported.Generating a PATTo generate a PAT, visit your GitHub settings page, then navigate to Developer Tools, and finally Personal Access Tokens (https://github.com/settings/tokens).Currently, this tool has been tested with "Token (classic)" PATs. It may be possible to use a fine-grained PAT, if you manage to do this please let us know!Currently, this tool utilizes thereposcope. Additional scopes may be required in the future as the capabilities of the tool expand.InstallationThere are two paths you can take to install, your choice will depend on what you intend to do withlaunch-cli. If you intend to use the tool's built-in commands as part of your normal role as a Launch engineer (this is the most common option), you should perform theEnd User Installationbelow. If you intend to develop additonal features forlaunch-cli, please follow theDevelopment Installationbelow.For either case, you will need to have Python 3.11 or greater installed on your system. How you choose to install that is up to you, but the installation steps assume you have an executable calledpython3.11in your path and thepipmodule installed.End User InstallationIssue the following command to install the latest version:python3.11-mpipinstall'git+https://github.com/nexient-llc/launch-cli.git#egg=launch'You can now use thelaunchcommand family from your CLI. Issuelaunch --helpto confirm the launch command is available in your shell.In the unlikely event that you need to install a specific version oflaunch-cliyou may specify a revision, branch name, or tag like so:# Tag 0.1.0 is used here, but you could specify a branch name or commit hash if desiredpython3.11-mpipinstall'git+https://github.com/nexient-llc/launch-cli.git@0.1.0#egg=launch'Development InstallationClone this repository to your machine and enter the repository's directory.Create a new virtual environment and activate it withpython3.11 -m venv .venv && source .venv/bin/activate.Issue the commandpython3.11 -m pip install -e '.[dev]'to create an editable installation.You can now use thelaunchcommand family from your CLI, and changes made to most code should be available the next time you run the CLI command, but changes to the entrypoint or pyproject.toml may require that you issue the pip install command again to update the generated shortcut.ZSH-specific configurationIf you use ZSH as your shell, we highly recommend you make one further modification to make development easier. By default, ZSH allows you to change directories without entering the cd command, which is a problem if you have a directory name that shadows the name of the command you're trying to run! Edit your ~/.zshrc file to include the following:# Disables changing directory without issuing the cd commandunsetoptautocdUpon sourcing the file or restarting, this will stop your shell from descending into the launch/ directory when your current working directory is the root of this repository.UsageOnce installed, you can use thelaunchcommand from your shell. Thelaunchcommand provides integrated helptext, which can be viewed by issuing the--helpflag, like so:$launch--help
Usage:launch[OPTIONS]COMMAND[ARGS]...LaunchCLItoolingtohelpautomatecommontasksperformedbyLaunchengineersandtheirclients.

Options:-v,--verboseIncreaseverbosityofallsubcommands--helpShowthismessageandexit.

Commands:githubCommandfamilyforGitHub-relatedtasks....We started with a group of commands undergithub, but you should expect the list of available commands to grow as the tooling expands to cover more of our use cases. To dig into the commands (or subgroups) available, you may issue the--helpflag on a subcommand in the same way to explore a group of commands:$launchgithub--help
Usage:launchgithub[OPTIONS]COMMAND[ARGS]...CommandfamilyforGitHub-relatedtasks.

Options:--helpShowthismessageandexit.

Commands:accessCommandfamilyfordealingwithGitHubaccess.hooksCommandfamilyfordealingwithGitHubwebhooks.versionCommandfamilyfordealingwithGitHubversioning.One very important thing to keep in mind is that options correspond to the group or command and cannot be issued in arbitrary places in the command. To use the--verboseflag to increase the output, you must place it following thelaunchcommand and before any subcommands, as shown below:launch--verbosegithubaccess...