https://github.com/alajmo/mani
:robot: CLI tool to help you manage repositories
https://github.com/alajmo/mani
cli git golang
Last synced: 9 months ago
JSON representation
:robot: CLI tool to help you manage repositories
- Host: GitHub
- URL: https://github.com/alajmo/mani
- Owner: alajmo
- License: mit
- Created: 2019-10-22T20:05:11.000Z (about 6 years ago)
- Default Branch: main
- Last Pushed: 2024-10-15T21:31:22.000Z (about 1 year ago)
- Last Synced: 2024-10-17T09:43:04.938Z (about 1 year ago)
- Topics: cli, git, golang
- Language: Go
- Homepage: https://manicli.com
- Size: 1.7 MB
- Stars: 438
- Watchers: 7
- Forks: 23
- Open Issues: 19
-
Metadata Files:
- Readme: README.md
- Contributing: docs/contributing.md
- Funding: .github/FUNDING.yml
- License: LICENSE
- Roadmap: docs/roadmap.md
Awesome Lists containing this project
- awesome-go - mani - CLI tool to help you manage multiple repositories. (Utilities / Utility/Miscellaneous)
- awesome-github-repos - alajmo/mani - :robot: CLI tool to help you manage repositories (Go)
- awesome-go-plus - mani - CLI tool to help you manage multiple repositories.  (Utilities / Utility/Miscellaneous)
- fucking-awesome-go - mani - CLI tool to help you manage multiple repositories. (Utilities / Utility/Miscellaneous)
- awesome-go-cn - mani
- awesome-go - mani - CLI tool to help you manage multiple repositories. (Utilities / Utility/Miscellaneous)
- jimsghstars - alajmo/mani - :robot: CLI tool to help you manage repositories (Go)
- awesome-go - mani - CLI tool to help you manage multiple repositories. (Utilities / Utility/Miscellaneous)
- awesome-go-extra - mani - 10-22T20:05:11Z|2022-06-19T16:08:34Z| (Utilities / Fail injection)
- awesome-go-with-stars - mani - CLI tool to help you manage multiple repositories. (Utilities / Utility/Miscellaneous)
- awesome-go - alajmo/mani
- awesome-go - mani - CLI tool to help you manage multiple repositories. (Utilities / Utility/Miscellaneous)
- awesome-go - mani - CLI tool to help you manage multiple repositories. (Utilities / Utility/Miscellaneous)
- awesome-go-cn - mani
README
mani

`mani` is a CLI tool that helps you manage multiple repositories. It's useful when you are working with microservices, multi-project systems, multiple libraries, or just a collection of repositories and want a central place for pulling all repositories and running commands across them.
You specify repositories and commands in a config file and then run commands across all or a subset of the repositories.

Interested in managing your servers in a similar way? Checkout [sake](https://github.com/alajmo/sake)!
## Features
- Declarative configuration
- Clone multiple repositories with a single command
- Run custom or ad-hoc commands across multiple repositories
- Built-in TUI
- Flexible filtering
- Customizable theme
- Auto-completion support
- Portable, no dependencies
## Table of Contents
- [Installation](#installation)
- [Building From Source](#building-from-source)
- [Usage](#usage)
- [Create a New Mani Repository](#create-a-new-mani-repository)
- [Command Examples](#run-some-commands)
- [Documentation](#documentation)
- [License](#license)
## Installation
[](https://repology.org/project/mani/versions)
`mani` is available on Linux and Mac, with partial support for Windows.
* Binaries are available on the [release](https://github.com/alajmo/mani/releases) page
* via cURL (Linux & macOS)
```sh
curl -sfL https://raw.githubusercontent.com/alajmo/mani/main/install.sh | sh
```
* via Homebrew
```sh
brew tap alajmo/mani
brew install mani
```
* via MacPorts
```sh
sudo port install mani
```
* via Arch (AUR)
```sh
yay -S mani
```
* via Nix
```sh
nix-env -iA nixos.mani
```
* via Go
```sh
go get -u github.com/alajmo/mani
```
Auto-completion is available via `mani completion bash|zsh|fish|powershell` and man page via `mani gen`.
### Building From Source
1. Clone the repo
2. Build and run the executable
```sh
make build && ./dist/mani
```
## Usage
### Create a New Mani Repository
Run the following command inside a directory containing your `git` repositories:
```sh
$ mani init
```
This will generate **two** files:
- `mani.yaml`: Contains projects and custom tasks. Any subdirectory that has a `.git` directory will be included (add the flag `--auto-discovery=false` to turn off this feature)
- `.gitignore`: Includes the projects specified in `mani.yaml` file. To opt out, use `mani init --vcs=none`.
It can be helpful to initialize the `mani` repository as a git repository so that anyone can easily download the `mani` repository and run `mani` sync to clone all repositories and get the same project setup as you.
### Run Some Commands
```bash
# List all projects
$ mani list projects
# Count number of files in each project in parallel
$ mani exec --all --output table --parallel 'find . -type f | wc -l'
# Start TUI
mani tui
```
### Documentation
Checkout the following to learn more about mani:
- [Examples](examples)
- [Config](docs/config.md)
- [Commands](docs/commands.md)
- Documentation
- [Filtering Projects](docs/filtering_projects.md)
- [Variables](docs/variables.md)
- [Output](docs/output.md)
- [Changelog](/docs/changelog.md)
- [Roadmap](/docs/roadmap.md)
- [Project Background](docs/project-background.md)
- [Contributing](docs/contributing.md)
## [License](LICENSE)
The MIT License (MIT)
Copyright (c) 2020-2021 Samir Alajmovic