Skip to content
/ mars Public

Workspace layer for coding agents across polyrepos. Coordinated branches, tag-based filtering, zero dependencies.

License

Notifications You must be signed in to change notification settings

dean0x/mars

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Mars

License: MIT npm CI Website

Manage multiple Git repositories as one workspace.

Tag-based filtering, parallel operations, zero dependencies.

Mars CLI demo

Why Mars?

Coding agents can take features end-to-end in one repo — but most real engineering spans many. Mars creates a workspace where all repos live under one tree, so agents inherit shared config and developers get coordinated operations across the stack.

  • Workspace-level agent config — config at the workspace root is inherited by every repo automatically
  • Coordinated branchesmars branch feature-x --tag backend across all relevant repos
  • Tag-based filtering — target subsets of repos (--tag frontend, --tag backend)
  • Zero dependencies — pure bash 3.2+, works on macOS out of the box

Quick Install

npm install -g @dean0x/mars

See all installation methods for Homebrew, curl, and manual options.

Quick Start

mkdir my-project && cd my-project
mars init

mars add https://github.com/dean0x/mars-example-frontend.git --tags frontend,web
mars add https://github.com/dean0x/mars-example-backend.git --tags backend,api
mars add https://github.com/dean0x/mars-example-shared.git --tags shared

mars clone
mars status

Commands

Command Description
mars init Initialize a new workspace
mars add <url> [--tags t1,t2] Add a repository to config
mars clone [--tag TAG] Clone configured repositories
mars status [--tag TAG] Show status of all repositories
mars branch <name> [--tag TAG] Create branch on repositories
mars checkout <branch> [--tag TAG] Checkout branch on repositories
mars sync [--tag TAG] [--rebase] Pull latest changes
mars exec "<cmd>" [--tag TAG] Run command in each repository
mars list [--tag TAG] List configured repositories

Tag Filtering

Target subsets of repos using --tag:

# Only clone frontend repos
mars clone --tag frontend

# Create branch on backend repos only
mars branch feature-auth --tag backend

# Run npm install on all frontend repos
mars exec "npm install" --tag frontend

Configuration

mars.yaml

version: 1

workspace:
  name: "my-project"

repos:
  - url: git@github.com:org/frontend.git
    tags: [frontend, web]
  - url: git@github.com:org/backend.git
    path: api                    # optional custom path
    tags: [backend, api]

defaults:
  branch: main

Workspace Structure

my-project/
├── mars.yaml           # Workspace configuration
├── .gitignore          # Contains 'repos/'
└── repos/              # Cloned repositories (gitignored)
    ├── frontend/
    ├── backend/
    └── shared/

Installation

npm (recommended)

npm install -g @dean0x/mars

Or run without installing:

npx @dean0x/mars --help

Homebrew (macOS/Linux)

brew install dean0x/tap/mars

Shell Script

curl -fsSL https://raw.githubusercontent.com/dean0x/mars/main/install.sh | bash

Install a specific version:

MARS_VERSION=0.1.2 curl -fsSL https://raw.githubusercontent.com/dean0x/mars/main/install.sh | bash

Manual

git clone https://github.com/dean0x/mars.git
cd mars
./build.sh
cp dist/mars ~/.local/bin/  # or anywhere in PATH

Contributing

See CONTRIBUTING.md for development setup, architecture, and release process.

License

MIT

About

Workspace layer for coding agents across polyrepos. Coordinated branches, tag-based filtering, zero dependencies.

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •  

Languages