#git-repository #git #repository #project

bin+lib axolotl_git

project management cli

9 releases

0.3.2 Apr 17, 2024
0.3.1 Apr 16, 2024
0.2.3 Apr 13, 2024
0.2.0 Feb 18, 2024
0.1.0 Jan 25, 2024

#17 in #project

28 downloads per month

MIT license

89KB
2K SLoC

Axolotl Git

A repo management cli that will allow your projects to grow, and regenerate like an axolotl!

Getting Started

(Requires tmux, and fzf for majority of features)

Install

(Currently not supported on windows)

Using cargo

cargo install --locked axolotl_git

Using Github Releases

Download a release from here, and add it to a directory on your path.

Running

Add a projects directory file example: path: ~/.config/axl/personal_projects.yml

projects_directory: "/path/to/your/Projects"
include: 
  - /path/to/group/file.yml
  - remote: git@github.com:your_github/your_project.git
    tags: [test_tag]
  - remote: git@github.com:your_github/your_other_project.git
    name: renamed_project

Now let axl know you would like to use this file with:

  • an env var export AXL_PROJECTS_CONFIG_PATH=~/.config/axl/personal_projects.yml
  • a flag --projects-config-path=~/.config/axl/personal_projects.yml

Check the available commands

$ axl --help
project management cli

Usage: axl [OPTIONS] <COMMAND>

Commands:
  project  Commands for managing projects
  help     Print this message or the help of the given subcommand(s)

Options:
  -v, --verbose...                 Increase logging verbosity
  -q, --quiet...                   Decrease logging verbosity
  -c, --config-path <CONFIG_PATH>  Override '$XDG_CONFIG_HOME/axl/config.yml' or '$HOME/.axlrc.yml' defaults [env: AXL_CONFIG_PATH=]
  -h, --help                       Print help
  -V, --version                    Print version

Future Enhancements

  • Cache resolved project files and only update if there is a change to any of the project definition files.
  • Fancy fzf custom prompts like zoxide.

Tracing

This cli is instrumented with tokio tracing. If you increase the verbosity of the cli you will see more logs with details that can help with troubleshooting.

To modify the verbosity of the logs, use:

  • -v or -q for the console output.
  • RUST_LOG=<trace,debug,info,warn,error> for the traces that are shipped to the optional OTEL collector. (see this for more advanced options)

By default the otel collector layer is not added. If you would like traces to be exported to a collector, you should set the environment variable OTEL_COLLECTOR_URL to a url where your collector is running. This will configure the cli to export your traces with otlp to your collector. They can then be shipped out to any exporter of your choosing.

You can try this with the docker-compose.yml, and otel-collector-config.yml files in this repo.

  1. docker-compose up -d.
  2. OTEL_COLLECTOR_URL=http://localhost:4317/v1/traces axl project open -m tmux -vvvv.
  3. open http://localhost:16686/search in your browser.

References:

Dependencies

~18–33MB
~454K SLoC