{"id":50614889,"url":"https://github.com/algodesigner/octo","last_synced_at":"2026-06-06T07:04:08.981Z","repository":{"id":340119712,"uuid":"1164621514","full_name":"algodesigner/octo","owner":"algodesigner","description":"octo: A lightweight C utility to manage and automate Git operations across multiple sibling repositories as a single layered workspace.","archived":false,"fork":false,"pushed_at":"2026-03-05T11:46:11.000Z","size":146,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2026-03-05T15:40:55.530Z","etag":null,"topics":["automation","c","cli","devtools","git","git-tool","multi-repo","polyrepo","productivity","systems-programming","workflow","workspaces"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/algodesigner.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-02-23T09:48:29.000Z","updated_at":"2026-03-05T11:46:14.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/algodesigner/octo","commit_stats":null,"previous_names":["algodesigner/octo"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/algodesigner/octo","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/algodesigner%2Focto","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/algodesigner%2Focto/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/algodesigner%2Focto/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/algodesigner%2Focto/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/algodesigner","download_url":"https://codeload.github.com/algodesigner/octo/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/algodesigner%2Focto/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33972419,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-06T02:00:07.033Z","response_time":107,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["automation","c","cli","devtools","git","git-tool","multi-repo","polyrepo","productivity","systems-programming","workflow","workspaces"],"created_at":"2026-06-06T07:04:08.402Z","updated_at":"2026-06-06T07:04:08.976Z","avatar_url":"https://github.com/algodesigner.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# octo\n\n`octo` is a command-line utility designed to streamline work with multiple sibling Git repositories. Inspired by the Git \"octopus merge,\" `octo` allows you to treat a collection of standalone repositories as a single, layered system. This is an ideal alternative to monolithic repositories (monorepos) when you need to maintain separate lifecycles for components like IPC, business logic, drivers, and utilities, while still performing uniform operations across them.\n\n## Features\n\n- **Uniform Git Operations**: Run `pull`, `push`, `status`, `checkout`, and `clone` across all repositories in a workspace with a single command.\n- **Declarative Configuration**: Define your \"universe\" of projects and workspaces in a simple, human-readable text file.\n- **Custom Command Execution**: Run any shell command across all repositories using `octo exec`.\n- **Workspace Isolation**: Manage different sets of repositories (workspaces) and switch between them easily.\n- **No-Bloat Architecture**: Written in C for performance and minimal dependencies.\n\n## Installation\n\n`octo` requires a C99-compliant compiler (such as `gcc` or `clang`) and a standard C library.\n\n1. Clone the repository (or download the source).\n2. Navigate to the project directory.\n3. Build the utility:\n   ```bash\n   make\n   ```\n   This will create a `octo` binary in the root directory and use an `obj/` folder for intermediate build artifacts.\n\n4. (Optional) Move the resulting `octo` binary to your `PATH`:\n   ```bash\n   mv octo /usr/local/bin/\n   ```\n\n## Testing\n\n`octo` comes with a comprehensive test suite. To run the tests:\n\n```bash\nmake test\n```\n\nThis will build the `test_runner` and execute all test cases.\n\n## Configuration\n\n`octo` looks for a workspace definition file. By default, it expects this file at `~/.octo/workspaces`, but you can specify a custom file using the `--def` flag.\n\n### The Definition File Format\n\nThe definition file consists of two main sections: `projects` (default repositories) and `workspace` definitions.\n\n```text\n# This is a sample workspace definition file\n\n# Default projects to be included in workspaces\nprojects {\n    utils\n    ipc\n    business\n    trading\n    analytics\n    data\n    ai\n}\n\n# Workspace definitions mapping an alias to a physical path\nworkspace w1 -\u003e /Users/vlad/Documents/work/workspace {\n    # You can add workspace-specific projects here\n}\n\nworkspace w2 -\u003e /Users/vlad/Documents/work/workspace2 {\n}\n```\n\n- **`projects { ... }`**: Lists the subdirectory names of the Git repositories you want to manage.\n- **`workspace \u003calias\u003e -\u003e \u003cpath\u003e { ... }`**: Defines a workspace. The `\u003cpath\u003e` is the parent directory where the projects reside. You can define additional projects inside the curly braces that are specific to that workspace.\n\n## Usage\n\n```bash\nocto [options] command [arguments]\n```\n\n### Commands\n\n| Command | Description |\n| :--- | :--- |\n| `pull` | Performs `git pull -p` in all repository directories. |\n| `push` | Performs `git push` in all repository directories. |\n| `status` | Checks `git status --porcelain` and reports any changes. |\n| `checkout \u003cbranch\u003e` | Switches all repositories to the specified branch. |\n| `clone \u003curl_prefix\u003e` | Clones the repositories using the provided URL prefix (e.g., `octo clone git@github.com:myorg/`). |\n| `list` | Lists the absolute paths of all repositories in the workspace. |\n| `path \u003calias\u003e/\u003cproject\u003e` | Prints the full physical path to a specific project. |\n| `exec \u003ccommand\u003e` | Executes an arbitrary shell command in each repository directory. |\n| `version` | Prints the current version of `octo`. |\n\n### Options\n\n| Option | Description |\n| :--- | :--- |\n| `--def=\u003cfile\u003e` | Path to the workspace definition file. |\n| `--workspace=\u003cname\u003e`, `-w=\u003cname\u003e` | Target a specific workspace defined in your config. |\n| `--verbose`, `-v` | Enable verbose output (shows full command execution details). |\n| `--no-colour` | Disable ANSI color output. |\n\n## Common Workflows\n\n`octo` is designed to handle repetitive Git tasks across many repositories. Here are some common ways to use it:\n\n### 1. Setting Up a New Workspace\nOnce you have defined your projects and workspace in the definition file, you can clone all repositories at once:\n```bash\nocto clone git@github.com:myorg/\n```\n\n### 2. Global Status Check\nQuickly see which repositories have uncommitted changes or are out of sync with their remotes:\n```bash\nocto status\n\n# Check status for a specific workspace only\nocto -w=w1 status\n```\n\n### 3. Synchronising All Layers\nBring your entire system up to date with a single command:\n```bash\nocto pull\n```\n\n### 4. Branch Management\nSwitch the whole workspace to a new feature branch for coordinated development:\n```bash\nocto checkout feature/new-engine\n```\n\n### 5. Bulk Build and Cleanup\nExecute standard shell commands across all projects:\n```bash\n# Build all components\nocto exec make\n\n# Perform a deep clean in all repositories\nocto exec git clean -fdx\n```\n\n### 6. Quick Navigation\nYou can use `octo path` to quickly jump to workspace roots or specific projects:\n\n```bash\n# Go to the root of workspace 'w1'\ncd `octo path w1/.`\n\n# Go to the 'utils' project in workspace 'w1'\ncd `octo path w1/utils`\n```\n\n## Why octo?\nIn a layered system, components are often developed in parallel. Managing them as separate Git repositories allows for cleaner boundaries and independent versioning. However, common tasks (like checking the status of all layers or pulling updates for the whole system) become tedious. `octo` automates these chores, providing the convenience of a monorepo with the flexibility of polyrepo architecture.\n\n## License\n\n`octo` is released under the FreeBSD 3-Clause License. See the [LICENSE](LICENSE) file for the full text.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falgodesigner%2Focto","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falgodesigner%2Focto","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falgodesigner%2Focto/lists"}