{"id":41218668,"url":"https://github.com/xaoscience/dev-control","last_synced_at":"2026-01-23T00:10:22.416Z","repository":{"id":328335055,"uuid":"1115152897","full_name":"xaoscience/dev-control","owner":"xaoscience","description":"A collection of powerful CLI tools, scripts and templates for streamlined Git workflow, repository management, and shell productivity.","archived":false,"fork":false,"pushed_at":"2026-01-20T22:32:02.000Z","size":407,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"Main","last_synced_at":"2026-01-21T05:35:24.097Z","etag":null,"topics":["aliases","automation","bash","cli","developer-tools","devops","dotfiles","git","github","github-actions","productivity","repository-management","shell","shell-scripts","submodules","templates","workflow"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/xaoscience.png","metadata":{"files":{"readme":"docs/README.md","changelog":"CHANGELOG.md","contributing":"docs/CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"docs/CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"docs/SECURITY.md","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":"2025-12-12T12:20:13.000Z","updated_at":"2026-01-20T22:26:01.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/xaoscience/dev-control","commit_stats":null,"previous_names":["xaoscience/git-control","xaoscience/dev-control"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/xaoscience/dev-control","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xaoscience%2Fdev-control","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xaoscience%2Fdev-control/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xaoscience%2Fdev-control/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xaoscience%2Fdev-control/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/xaoscience","download_url":"https://codeload.github.com/xaoscience/dev-control/tar.gz/refs/heads/Main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xaoscience%2Fdev-control/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28675519,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-22T20:48:19.482Z","status":"ssl_error","status_checked_at":"2026-01-22T20:48:14.968Z","response_time":144,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["aliases","automation","bash","cli","developer-tools","devops","dotfiles","git","github","github-actions","productivity","repository-management","shell","shell-scripts","submodules","templates","workflow"],"created_at":"2026-01-23T00:10:21.820Z","updated_at":"2026-01-23T00:10:22.402Z","avatar_url":"https://github.com/xaoscience.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Dev-Control\n\n\u003c!-- Project Shields/Badges --\u003e\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/xaoscience/dev-control\"\u003e\n    \u003cimg alt=\"GitHub repo\" src=\"https://img.shields.io/badge/GitHub-xaoscience%2Fdev--control-181717?style=for-the-badge\u0026logo=github\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/xaoscience/dev-control/releases\"\u003e\n    \u003cimg alt=\"GitHub release\" src=\"https://img.shields.io/github/v/release/xaoscience/dev-control?style=for-the-badge\u0026logo=semantic-release\u0026color=blue\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/xaoscience/dev-control/blob/main/LICENSE\"\u003e\n    \u003cimg alt=\"License\" src=\"https://img.shields.io/github/license/xaoscience/dev-control?style=for-the-badge\u0026color=green\"\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/xaoscience/dev-control/actions/workflows/bash-lint.yml\"\u003e\n    \u003cimg alt=\"CI Status\" src=\"https://github.com/xaoscience/dev-control/actions/workflows/bash-lint.yml/badge.svg?branch=Main\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/xaoscience/dev-control/issues\"\u003e\n    \u003cimg alt=\"Issues\" src=\"https://img.shields.io/github/issues/xaoscience/dev-control?style=flat-square\u0026logo=github\u0026color=yellow\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/xaoscience/dev-control/pulls\"\u003e\n    \u003cimg alt=\"Pull Requests\" src=\"https://img.shields.io/github/issues-pr/xaoscience/dev-control?style=flat-square\u0026logo=github\u0026color=purple\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/xaoscience/dev-control/stargazers\"\u003e\n    \u003cimg alt=\"Stars\" src=\"https://img.shields.io/github/stars/xaoscience/dev-control?style=flat-square\u0026logo=github\u0026color=gold\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/xaoscience/dev-control/network/members\"\u003e\n    \u003cimg alt=\"Forks\" src=\"https://img.shields.io/github/forks/xaoscience/dev-control?style=flat-square\u0026logo=github\"\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg alt=\"Last Commit\" src=\"https://img.shields.io/github/last-commit/xaoscience/dev-control?style=flat-square\u0026logo=git\u0026color=blue\"\u003e\n  \u003cimg alt=\"Repo Size\" src=\"https://img.shields.io/github/repo-size/xaoscience/dev-control?style=flat-square\u0026logo=files\u0026color=teal\"\u003e\n  \u003cimg alt=\"Code Size\" src=\"https://img.shields.io/github/languages/code-size/xaoscience/dev-control?style=flat-square\u0026logo=files\u0026color=orange\"\u003e\n  \u003cimg alt=\"Contributors\" src=\"https://img.shields.io/github/contributors/xaoscience/dev-control?style=flat-square\u0026logo=github\u0026color=green\"\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg alt=\"Stability\" src=\"https://img.shields.io/badge/stability-experimental-orange?style=flat-square\"\u003e\n  \u003cimg alt=\"Maintenance\" src=\"https://img.shields.io/maintenance/yes/2026?style=flat-square\"\u003e\n  \u003cimg alt=\"Shell\" src=\"https://img.shields.io/badge/shell-bash-4EAA25?style=flat-square\u0026logo=gnu-bash\u0026logoColor=white\"\u003e\n\u003c/p\u003e\n\n---\n\n\u003cp align=\"center\"\u003e\n  \u003cb\u003e🛠️ A collection of powerful CLI tools and scripts for streamlined Git workflow, repository management, and shell productivity.\u003c/b\u003e\n\u003c/p\u003e\n\n---\n\n## 📋 Table of Contents\n\n- [Overview](#-overview)\n- [Features](#-features)\n- [Installation](#-installation)\n- [Usage](#-usage)\n- [Scripts](#-scripts)\n- [Documentation](#-documentation)\n- [Contributing](#-contributing)\n- [Roadmap](#-roadmap)\n- [Support](#-support)\n- [License](#-license)\n\n---\n\n## 🔍 Overview\n\n**Dev-Control** is a comprehensive toolkit designed to enhance your Git and shell workflow. It provides:\n\n- **Alias Management**: Interactive setup of productivity-boosting shell aliases\n- **Template Loading**: Quick initialisation of new repositories with standardised templates\n- **Module Nesting**: Automated management of Git submodules in complex project hierarchies\n- **Workflow Templates**: Pre-configured GitHub Actions for common automation tasks\n\n### Why Dev-Control?\n\nManaging multiple repositories, nested submodules, and maintaining consistent configurations across projects is time-consuming and error-prone. Dev-Control automates these tasks while remaining portable and easy to share across systems.\n\n---\n\n## ✨ Features\n\n- 🚀 **Interactive Alias Installer** - Dynamically detects script paths and creates portable aliases\n- 🔧 **Template System** - Initialise repos with docs, workflows, and configuration templates\n- 📦 **Submodule Management** - Auto-generate `.gitmodules` and maintain `.tmp` for nested repos\n- 🔒 **Safety Aliases** - Protective wrappers for dangerous commands (`rm`, `mv`, `cp`)\n- ⚡ **Git Shortcuts** - Optimised aliases for common Git operations\n- 🐳 **Container Shortcuts** - Quick access to Docker/Podman commands\n- 🌐 **Network Utilities** - IP checking, port monitoring, and connectivity tools\n- 📁 **Directory Operations** - Enhanced navigation and file management\n- 🤖 **GitHub MCP Setup** - Automated GitHub MCP server configuration for VS Code with secure token management\n- 📦 **Multi-Platform Packaging** - Build tarballs, Homebrew, Snap, Debian, Nix, and Docker packages\n- 🎨 **Glamorous TUI Theming** - Charmbracelet Gum integration with matrix/hacker/cyber themes\n- 🌐 **Web Terminal** - Docker packages with ttyd for browser-based access\n- 🐳 **Devcontainer Setup** - Auto-configure rootless podman and generate optimised devcontainer.json with secure mounts\n\n---\n\n## 📥 Installation\n\n### Prerequisites\n\n- Bash 4.0+ or Zsh\n- Git 2.0+\n- Standard Unix utilities (`find`, `sed`, `grep`)\n\n### Quick Start\n\n```bash\n# Clone the repository\ngit clone https://github.com/xaoscience/dev-control.git\ncd dev-control\n\n# Run the interactive alias installer\n./scripts/alias-loading.sh\n\n# Or run individual scripts\n./scripts/template-loading.sh\n./scripts/module-nesting.sh\n```\n\n### Manual Installation\n\n```bash\n# Add to your .bashrc or .bash_profile\nsource /path/to/dev-control/scripts/alias-loading.sh --source-only\n```\n\n---\n\n## 🚀 Usage\n\n### Main Menu\n\nUse the main `dev-control.sh` wrapper to access all tools via interactive menu:\n\n```bash\n# Interactive menu - choose any tool\n./scripts/dev-control.sh\n\n# Or use the alias (after running alias-loading.sh)\ndc-control\n\n# Direct command mode - skip the menu\n./scripts/dev-control.sh repo      # Create repository\n./scripts/dev-control.sh pr        # Create pull request\n./scripts/dev-control.sh fix       # Fix commit history\n```\n\n### Alias Loading\n\n```bash\n\n# Interactive installation - choose which alias categories to install\n./scripts/alias-loading.sh \u0026\u0026 source ~/.bashrc\n\n# Reinstall all and automatically reload\ndc-aalias\n```\n\n### Alias Usage\n\n**Categories:**\n\n| Category | Commands / Notes |\n| --- | --- |\n| **Git Control (dc-*)** | `dc-fix`, `dc-pr`, `dc-create`, `dc-mcp` |\n| **Git Shortcuts** | `gs`, `ga`, `gc`, `gp`, `gl` |\n| **Safety Nets** | `rm -i`, `cp -i`, `mv -i` under aliases of `rm`, `cp`, `mv`|\n| **System Monitoring** | `ports`, `meminfo`, `disk` |\n| **Directory Operations** | `md`, `rd`, `..`, `ll` |\n| **Network Utilities** | `myip`, `ping`, `fastping` |\n| **Container Shortcuts** | `dps`, `dpsa`, `drm`, `drmi` |\n| **Quick Edits** | `bashrc`, `reload` |\n\n**Examples**\n\n```bash\n# Git commit amend (no edit) and push force\ngca\n\n# Similar amend, with original author date (also restores it after gca)\ngcda\n\n# Git push force with lease\ngcpf\n\n# Decorated, oneline Git log\ngl\n```\n\n*Tip: run `./scripts/alias-loading.sh` and `source ~/.bashrc` to install or refresh aliases.*\n### Template Loading\n\nAllows for creation of new $NAME-templates folders, which will be copied by default.\n\n**Note:** During interactive setup you can specify the repository owner (GitHub username or organisation). By default `dc-init` will use the detected org from the remote or your `gh` account, but you may override it.\n\n```bash\n# Interactive mode - initialise a new repo with templates\ndc-init\n\n# Or run directly\n./scripts/template-loading.sh\n\n# CLI mode - update specific files with path support\n./scripts/template-loading.sh -f docs/CONTRIBUTING.md,docs/SECURITY.md -o\n\n# CLI options:\n#   -f, --files FILE1,FILE2    Process specific files (supports paths like docs/FILE.md)\n#   -o, --overwrite            Overwrite existing files without prompting\n#   -h, --help                 Show help and list available templates\n```\n\n### Repository Creation\n\n```bash\n# Interactive creation of new GitHub repository\ndc-create\n\n# Or run directly\n./scripts/create-repo.sh\n```\n\n### Pull Request Creation\n\n```bash\n# Interactive creation of pull request from current branch\ndc-pr\n\n# Or run directly\n./scripts/create-pr.sh\n```\n\n### Module Nesting\n\n```bash\n# Scan current directory for git repos and generate .gitmodules\ndc-modules\n\n# Or run directly\n./scripts/module-nesting.sh\n\n# Specify a custom root directory\n./scripts/module-nesting.sh /path/to/project\n```\n\n#### Extra features\n\nUse the action flags below to manage per-module temporary folders after module-nesting (e.g. `--copy-temp`) or independently (e.g. `--only-copy-temp`). All flows support `--dry-run` for safe previews.\n\n##### Feature breakdown\n\n- `--copy-temp` / `--only-copy-temp`\n  - What it does: Collects temporary folders (e.g., `.tmp`, `tmp`, `.temp`) and merges their contents into per-parent directories under `\n`$ROOT/.tmp/\u003cparent\u003e` non-destructively (does not overwrite existing files).\n  - When to use: Consolidate per-module temporary build outputs for cleanup or archiving.\n  - Preview: `./scripts/module-nesting.sh --only-copy-temp --dry-run /path/to/project`\n\n- `--prune` / `--only-prune`\n  - What it does: Moves originals to a recycle location (or deletes with `--delete`) and replaces originals with symlinks pointing at `\n`$ROOT/.tmp/\u003cparent\u003e`.\n  - If no copied record exists, `--only-prune --dry-run` simulates a `--only-copy-temp --dry-run` `\n`$ROOT/.tmp/\u003cparent\u003e` destinations rather than ephemeral `/tmp` paths.\n  - Preview: `./scripts/module-nesting.sh --only-prune --dry-run /path/to/project`\n\n- `--aggressive`\n  - What it does: Merges temp folders into `\n`$ROOT/.tmp/\u003cparent\u003e`, removes original temp folders, replaces them with directory symlinks, and appends entries to the nearest `.gitignore` (except for folders named `.tmp`).\n  - Preview: `./scripts/module-nesting.sh --aggressive --dry-run /path/to/project` (reports merges, removals, and `.gitignore` changes; reports `already contains` when no change is needed)\n\n- `--dry-run` behavior\n  - Use `--dry-run` with any flow to preview actions without modifying your workspace.\n  - `.gitmodules` generation now respects `--dry-run` and will report file writes/removals; enable `DEBUG=true` to preview content snippets during a dry-run.\n\n- `--test`\n  - Runs a safe `copy-temp` → `prune` → `aggressive` sequence in `--dry-run` mode: `./scripts/module-nesting.sh --test`\n\nExamples:\n\n```bash\n# Preview .gitmodules generation without making changes\n./scripts/module-nesting.sh --dry-run /path/to/project -y\n\n# Preview copy -\u003e prune -\u003e aggressive sequence\n./scripts/module-nesting.sh --test\n\n# Preview aggressive changes (including .gitignore simulation)\n./scripts/module-nesting.sh --aggressive --dry-run /path/to/project\n```\n\n\u003e Tip: Run with `DEBUG=true` (for example `DEBUG=true ./scripts/module-nesting.sh --dry-run /path -y`) for additional diagnostic output and a content preview of simulated `.gitmodules`.\n\n\n\n\n### History Fixing\n\nInteractively rewrite commit history with fine-grained control over commit messages, author/committer dates, signing and reconstruction strategies.\n\n##### Feature breakdown\n\n- `--range` / `-r`\n  - Select a commit range to operate on (default: `HEAD=10`). Examples: `HEAD=5`, `main..HEAD`, `abc123..def456`.\n\n- `--amend` / `-a`\n  - Amend a non-tip commit while preserving dates and optionally signing the amended commit. Example: `--amend HEAD=2`.\n\n- `--sign` / `--atomic-preserve`\n  - `--sign`: re-sign commits in the selected range (requires GPG).\n  - `--atomic-preserve`: recreate commits deterministically (including merges) with `git commit-tree`, sign them and set author/committer dates atomically.\n\n- `--drop`\n  - Remove a single non-root commit from history (specify commit hash).\n\n- Harness \u0026 safety helpers (`--harness-drop`, `--harness-sign`, `--harness-no-cleanup`)\n  - Run minimal harnesses that apply operations safely in a temporary branch and produce a backup bundle for inspection.\n\n- Conflict \u0026 reconstruction options (`--auto-resolve`, `--reconstruct-auto`, `--allow-override`)\n  - `--auto-resolve \u003cours|theirs\u003e` will auto-add conflicted files using the chosen strategy during rebase.\n  - `--reconstruct-auto` retries reconstruction with common strategies on failure.\n  - `--allow-override` skips confirmation when replacing the original branch with a temporary branch.\n\n- Worktree \u0026 restore helpers (`--update-worktrees`, `--restore`)\n  - `--update-worktrees` detects local worktrees with the branch checked out and updates them safely (creates bundle backup).\n  - `--restore` lists and restores backup bundles/tags interactively.\n\n- Dry-run \u0026 diagnostic (`-d`, `--dry-run`, `-v`)\n  - Use `--dry-run` to preview all changes without applying them; `-v` or `--verbose` increases diagnostic output.\n\n- Stash support (`-s`)\n  - `--stash N` lets you selectively apply files from `stash@{N}` into the rewritten commits.\n\n- Cleanup options (`--no-cleanup`, `--only-cleanup`)\n  - `--no-cleanup`: skip the interactive cleanup prompt at the end of a run and do not offer to delete temporary backup refs or branches.\n  - `--only-cleanup`: only perform cleanup of temporary tags, bundles and backup branches (useful to tidy harness artifacts after a failed run).\n\n##### Env vars vs CLI flags\n\nMost behaviours are available either via environment variables or equivalent CLI flags. Common env vars you may use are: `PRESERVE_TOPOLOGY`, `UPDATE_WORKTREES`, `NO_EDIT_MODE`, `AUTO_FIX_REBASE`, `RECONSTRUCT_AUTO` — you can set these in your shell or pass the corresponding flags when invoking the script.\n\n##### Examples\n\n```bash\n# Interactive: edit the last 10 commits\n./scripts/fix-history.sh\n\n# Preview changes without applying\n./scripts/fix-history.sh --dry-run --range HEAD=20\n\n# Re-sign an entire branch and show verbose output\n./scripts/fix-history.sh --sign --range HEAD=all -v\n\n# Use env-vars (equivalent to flags) for a non-interactive run\nPRESERVE_TOPOLOGY=TRUE UPDATE_WORKTREES=true NO_EDIT_MODE=true AUTO_FIX_REBASE=true RECONSTRUCT_AUTO=true \\\n  ./scripts/fix-history.sh --sign --range HEAD=all -v\n```\n\n\u003e Tip: When experimenting with large-scale rewrites, prefer `--dry-run` and harness modes to capture backups before making changes.\n### GitHub MCP Server Setup\n\nAutomatically configure GitHub MCP and additional MCP servers for VS Code with secure token management:\n\n```bash\n# Full interactive setup - initialize MCP and configure servers\ndc-mcp\n\n# Or run directly\n./scripts/mcp-setup.sh\n\n# Configuration-only mode (with existing token)\n./scripts/mcp-setup.sh --config-only\n\n# Test existing MCP connection\n./scripts/mcp-setup.sh --test\n\n# Show current token info (masked)\n./scripts/mcp-setup.sh --show-token\n\n# Options:\n#   (no args)           Initialize MCP and select servers to install (DEFAULT)\n#   --config-only       Only generate MCP base configuration\n#   --test              Test GitHub MCP connection\n#   --show-token        Display current token info (masked)\n#   --help              Show help message\n```\n#### What it does:\n- ✅ Authenticates with your GitHub account\n- ✅ Creates a Personal Access Token (PAT) with minimal required scopes\n- ✅ Sets a 90-day expiration policy for security\n- ✅ Generates VS Code MCP settings with secure variable substitution:\n  - Optimal mounts for GPG, docker/podman, git, wrangler\n  - Configured git user and optional GPG signing (script prompts for your key ID; no key material is embedded)\n- ✅ Offers interactive server selection:\n  - GitHub MCP (HTTP remote) — GitHub API access\n  - Stack Overflow MCP (HTTP remote) — Search Q\u0026A\n  - Firecrawl MCP (Docker/NPX) — Web scraping and crawling\n- ✅ All servers appear consistently as manually installed\n- ✅ Token is saved in the system keychain or prompted per VS Code session (secure input)\n\n### Devcontainer Setup\n\nAuto-configure rootless podman and generate optimised `.devcontainer/devcontainer.json`:\n\n```bash\n# Interactive setup - detects project path or prompts for input\ndc-contain\n\n# Or run directly\n./scripts/containerise.sh\n\n# Specify custom project path\n./scripts/containerise.sh /path/to/project\n\n# Options:\n#   (no args)           Uses current directory\n#   /path/to/project    Specify custom project path\n#   --help              Show help message\n```\n\n#### What it does:\n- ✅ Checks for rootless podman (installs if needed)\n- ✅ Detects system paths (GPG, podman socket, git config, etc.)\n- ✅ Generates `.devcontainer/devcontainer.json` with:\n  - Optimal mounts for GPG, docker/podman, git, wrangler\n  - Configured git user and optional GPG signing (script prompts for your key ID; no key material is embedded)\n  - Universal devcontainer image\n- ✅ Guides VS Code reopening with devcontainer activation\n- ✅ Ensures configurations persist and work across sessions\n\n### Multi-Platform Packaging\n\nBuild and distribute dev-control (or any bash CLI tool) across multiple platforms with glamorous TUI theming:\n\n```bash\n# Interactive mode - menu-driven package selection\ndc-package\n\n# Or run directly\n./scripts/packaging.sh\n\n# Initialize packaging configuration\n./scripts/packaging.sh --init\n\n# Build specific package types\n./scripts/packaging.sh --tarball              # Release archive (.tar.gz)\n./scripts/packaging.sh --homebrew             # Homebrew formula\n./scripts/packaging.sh --snap                 # Snap package\n./scripts/packaging.sh --debian               # Debian package (.deb)\n./scripts/packaging.sh --nix                  # Nix flake\n./scripts/packaging.sh --docker               # Docker image with ttyd web terminal\n\n# Build all packages at once\n./scripts/packaging.sh --all\n\n# Build with specific theme\n./scripts/packaging.sh --theme cyber --all\n\n# Options:\n#   --init              Create .dc-package.yaml configuration\n#   --all               Build all package types\n#   --tarball           Build release tarball with SHA256\n#   --homebrew          Generate Homebrew formula\n#   --snap              Generate Snap package config\n#   --debian            Build Debian package structure\n#   --nix               Generate Nix flake\n#   --docker            Build Docker image with ttyd web interface\n#   --theme THEME       Set UI theme (matrix, hacker, cyber)\n#   -o, --output DIR    Output directory (default: ./dist)\n#   --dry-run           Preview without building\n#   --verbose           Show detailed output\n#   --help              Show help message\n```\n\n#### Supported Package Formats\n\n| Format | Output | Install Method |\n|--------|--------|----------------|\n| **Tarball** | `.tar.gz` + SHA256 | `./install.sh` |\n| **Homebrew** | Ruby formula | `brew install` |\n| **Snap** | `snapcraft.yaml` | `snap install` |\n| **Debian** | `.deb` structure | `dpkg -i` / `apt install` |\n| **Nix** | `flake.nix` | `nix build` / `nix develop` |\n| **Docker** | `Dockerfile` + compose | `docker run` with web terminal |\n\n#### TUI Theming\n\nPackaging integrates with [Charmbracelet Gum](https://github.com/charmbracelet/gum) (see [license](https://github.com/charmbracelet/gum/blob/6045525ab92f75c169d3c69596844d8748437e37/LICENSE)) for glamorous terminal UI with 3 built-in themes:\n\n| Theme | Style | Colour |\n|-------|-------|--------|\n| **matrix** | Green fluorescent terminal | 🟢 `#00ff00` |\n| **hacker** | Orange/amber retro | 🟠 `#ff8c00` |\n| **cyber** | Blue cyberpunk neon | 🔵 `#00d4ff` |\n\nSet theme via environment variable or CLI:\n\n```bash\n# Environment variable (persists for session)\nexport DC_THEME=matrix\n\n# CLI flag (per-command)\n./scripts/packaging.sh --theme hacker --docker\n\n# Docker with theme\ndocker run -p 8080:8080 -e DC_THEME=cyber dev-control\n```\n\n#### Configuration File\n\nRun `--init` to create `.dc-package.yaml`:\n\n```yaml\n# .dc-package.yaml\nname: my-tool\nversion: 1.0.0\ndescription: \"My awesome CLI tool\"\nhomepage: https://github.com/user/repo\nlicense: MIT\nmaintainer: \"Name \u003cemail@example.com\u003e\"\nentry_point: ./main.sh\ntheme: matrix\n\ninclude:\n  - scripts/\n  - config/\n  - docs/\n  - README.md\n  - LICENSE\n\ndependencies:\n  - git\n  - gh\n  - jq\n  - gum\n```\n\n#### Docker Web Terminal\n\nThe Docker package includes [ttyd](https://github.com/tsl0922/ttyd) for browser-based terminal access:\n\n```bash\n# Build and run\ncd dist/docker\ndocker build -t dev-control .\ndocker run -p 8080:8080 -e DC_THEME=matrix dev-control\n\n# Access at http://localhost:8080\n\n# Or run all themed instances with docker-compose\ndocker-compose --profile themed up --build\n# Matrix: http://localhost:8081\n# Hacker: http://localhost:8082\n# Cyber:  http://localhost:8083\n```\n\n---\n\n## 📜 Scripts\n\n| Script | Description |\n|--------|-------------|\n| [`dev-control.sh`](../scripts/dev-control.sh) | **Main entry point** - Interactive menu for all tools |\n| [`alias-loading.sh`](../scripts/alias-loading.sh) | Interactive alias installer with category selection |\n| [`template-loading.sh`](../scripts/template-loading.sh) | Repository template initialisation tool |\n| [`create-repo.sh`](../scripts/create-repo.sh) | Interactive GitHub repository creator |\n| [`create-pr.sh`](../scripts/create-pr.sh) | Interactive pull request creator |\n| [`module-nesting.sh`](../scripts/module-nesting.sh) | Automated `.gitmodules` generator for nested repos |\n| [`fix-history.sh`](../scripts/fix-history.sh) | Interactive commit history rewriting tool |\n| [`mcp-setup.sh`](../scripts/mcp-setup.sh) | GitHub \u0026 additional MCP server setup for VS Code with token management |\n| [`containerise.sh`](../scripts/containerise.sh) | Rootless podman setup and devcontainer.json generator with mount configuration |\n| [`packaging.sh`](../scripts/packaging.sh) | Multi-platform package builder with TUI theming (tarball, Homebrew, Snap, Debian, Nix, Docker) |\n| [`git-control.sh`](../scripts/git-control.sh) | Unified git operations wrapper (staging, committing, pushing, PRs) |\n\n### Shared Libraries\n\n| Library | Description |\n|---------|-------------|\n| [`lib/tui.sh`](../scripts/lib/tui.sh) | Gum-based TUI wrapper with 3 themes (matrix, hacker, cyber) and fallback support |\n| [`lib/colors.sh`](../scripts/lib/colors.sh) | ANSI colour definitions for terminal output |\n| [`lib/print.sh`](../scripts/lib/print.sh) | Formatted print functions (headers, info, success, errors) |\n| [`lib/config.sh`](../scripts/lib/config.sh) | Configuration file loading and validation |\n| [`lib/git-utils.sh`](../scripts/lib/git-utils.sh) | Git helper functions (branch detection, remote parsing) |\n| [`lib/validation.sh`](../scripts/lib/validation.sh) | Input validation utilities |\n\n### Doc Templates\n\n| Template | Description |\n|----------|-------------|\n| [`README.md`](../docs-templates/README.md) | Full-featured README with badges and sections |\n| [`CONTRIBUTING.md`](../docs-templates/CONTRIBUTING.md) | Contribution guidelines template |\n| [`CODE_OF_CONDUCT.md`](../docs-templates/CODE_OF_CONDUCT.md) | Community code of conduct |\n| [`SECURITY.md`](../docs-templates/SECURITY.md) | Security policy template |\n\n### License Templates\n\n| Template | Description |\n|----------|-------------|\n| [`Apache License 2.0`](../license-templates/Apache-2.0) | Permissive with explicit patent grant and NOTICE handling |\n| [`BSD 3-Clause`](../license-templates/BSD-3-Clause) | Permissive license with non-endorsement clause |\n| [`GNU GPL v3.0`](../license-templates/GPL-3.0) | Strong copyleft — modifications must be released under GPLv3 |\n| [`MIT License`](../license-templates/MIT) | Very permissive, minimal requirements |\n\n### GitHub Templates\n\n| Template | Description |\n|----------|-------------|\n| [`ISSUE_TEMPLATE/bug_report.md`](../github-templates/ISSUE_TEMPLATE/bug_report.md) | Bug report issue template |\n| [`ISSUE_TEMPLATE/feature_request.md`](../github-templates/ISSUE_TEMPLATE/feature_request.md) | Feature request issue template |\n| [`PULL_REQUEST_TEMPLATE.md`](../github-templates/PULL_REQUEST_TEMPLATE.md) | Pull request template |\n\n### Workflow Templates\n\n| Workflow | Description |\n|----------|-------------|\n| [`dependabot-automerge.yml`](../workflows-templates/dependabot-automerge.yml) | Auto-merge Dependabot PRs |\n| [`init.yml`](../workflows-templates/init.yml) | Standalone workflow - copy to any repo |\n| [`remote-init.yml`](../workflows-templates/remote-init.yml) | Calls the reusable workflow remotely |\n\n### Workflows\n\n| Workflow | Description |\n|----------|-------------|\n| [`central-loader.yml`](../.github/workflows/central-loader.yml) | Reusable workflow (call from other repos) |\n\n---\n\n## 🔄 GitHub Actions Workflows\n\nIn addition to initialising from local (dc-init), Dev-Control provides two ways to initialise templates via GitHub Actions:\n\n### Option 1: Standalone Workflow (Recommended)\n\nCopy `workflows-templates/init.yml` to your repo's `.github/workflows/` folder.\n\n```bash\n# From your target repository\nmkdir -p .github/workflows\ncurl -sL https://raw.githubusercontent.com/xaoscience/dev-control/main/workflows-templates/init.yml \\\n  -o .github/workflows/init.yml\ngit add .github/workflows/init.yml\ngit commit -m \"Add template initialisation workflow\"\ngit push\n```\n\nThen go to **Actions** → **Initialise Repository Templates** → **Run workflow**\n\n### Option 2: Reusable Workflow (Remote)\n\nCopy `workflows-templates/remote-init.yml` or call Dev-Control's reusable workflow directly:\n\n```yaml\n# .github/workflows/remote-init.yml\nname: Initialise Documentation\n\non:\n  workflow_dispatch:\n\npermissions:\n  contents: write\n  pull-requests: write\n\njobs:\n  init-templates:\n    uses: xaoscience/dev-control/.github/workflows/central-loader.yml@main\n    with:\n      project_name: 'My Project'\n      short_description: 'A cool project'\n      license_type: 'MIT'\n      stability: 'experimental'\n      templates: 'all'\n      create_pr: true\n```\n\n### Workflow Features\n\n- ✅ **No PAT required** - Uses standard `GITHUB_TOKEN`\n- ✅ **Creates PR by default** - Review before merging\n- ✅ **Configurable** - Choose templates, license, stability\n- ✅ **Auto-populates** - Fills in repo name, org, URLs automatically\n- ✅ **Dynamic folders** - Scans all `*-templates` folders for future expansion\n\n---\n\n## 📚 Documentation\n\n| Document | Description |\n|----------|-------------|\n| [📖 README](docs/README.md) | This file - project overview |\n| [🤝 Contributing](docs/CONTRIBUTING.md) | How to contribute |\n| [📜 Code of Conduct](docs/CODE_OF_CONDUCT.md) | Community guidelines |\n| [🔒 Security](docs/SECURITY.md) | Security policy |\n\n---\n\n## 🤝 Contributing\n\nContributions are welcome! Please read our [Contributing Guidelines](CONTRIBUTING.md) before submitting PRs.\n\n1. Fork the repository\n2. Create your feature branch (`git checkout -b feature/AmazingFeature`)\n3. Commit your changes (`git commit -m 'Add some AmazingFeature'`)\n4. Push to the branch (`git push origin feature/AmazingFeature`)\n5. Open a Pull Request\n\nSee also: [Code of Conduct](CODE_OF_CONDUCT.md) | [Security Policy](SECURITY.md)\n\n---\n\n## 🗺️ Roadmap\n\n- [x] Core alias loading script with interactive selection\n- [x] Template system for repository documentation\n- [x] Submodule nesting management\n- [x] Dependabot automerge workflow\n- [x] GitHub Actions workflow for remote template initialisation\n- [x] Reusable workflow for cross-repo template loading\n- [x] Config file support for persistent preferences\n- [x] Multi-platform packaging (tarball, Homebrew, Snap, Debian, Nix, Docker)\n- [x] Glamorous TUI theming with Charmbracelet Gum\n- [x] Web terminal support via ttyd in Docker packages\n- [ ] Zsh compatibility layer\n- [ ] Fish shell support\n- [ ] GUI wrapper / desktop app (Tauri, Wails, or Bubble Tea)\n- [ ] Plugin system for custom alias categories\n\nSee the [open issues](https://github.com/xaoscience/dev-control/issues) for a full list of proposed features and known issues.\n\n---\n\n## 💬 Support\n\n- 💻 **Issues**: [GitHub Issues](https://github.com/xaoscience/dev-control/issues)\n- 💬 **Discussions**: [GitHub Discussions](https://github.com/xaoscience/dev-control/discussions)\n\n---\n\n## 📄 License\n\nDistributed under the GPL-3.0 License. See [`LICENSE`](../LICENSE) for more information.\n\n---\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/xaoscience\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/Made%20with%20%E2%9D%A4%EF%B8%8F%20by-xaoscience-red?style=for-the-badge\"\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"#dev-control\"\u003e⬆️ Back to Top\u003c/a\u003e\n\u003c/p\u003e","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxaoscience%2Fdev-control","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fxaoscience%2Fdev-control","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxaoscience%2Fdev-control/lists"}