Skip to content

Repository files navigation

AtomGit CLI (ag)

License npm Latest Release CI Status Homebrew Go Reference GoReleaser

AtomGit 命令行工具,参考 GitHub CLI (gh) 开发。

English: README.en.md

功能

类别 能力
📦 仓库 列出、查看、创建、编辑、克隆、删除、复刻和同步仓库,管理仓库级推送规则
👥 协作者 列出、查看、添加、修改和移除仓库协作者
🔔 Webhook 列出、查看、创建、编辑、删除和测试仓库 Webhook
🌿 分支 列出、查看、创建和删除分支,管理分支保护规则
🔀 Pull Request 列出、查看、创建、编辑、关闭、重开、审查、合并和检出 PR,查看差异与检查结果,管理评论和关联 Issue
🐛 Issue 列出、查看、创建、编辑、关闭和重开 Issue,管理标签和评论
🔖 标签 列出、创建、编辑和删除仓库标签
🎯 里程碑 列出、查看、创建、编辑、关闭、重开和删除里程碑
🏷️ Tag 列出、创建和删除 Git tag,管理保护 tag 规则
🚀 Release 列出、查看、创建和编辑 Release,上传和下载附件
⚙️ Actions 列出、校验和触发 workflow;查看 workflow 运行、job、日志与 artifact,并下载日志和 artifact
🏢 组织 列出当前账号加入的组织
🔍 搜索 搜索仓库、用户和 Issue
💬 Discussion 列出仓库 Discussion
🔔 通知 列出仓库通知并标记已读
🔐 认证与 SSH Key OAuth 登录、刷新和切换账号,查看认证状态,管理 SSH 公钥
🌐 API 调用 AtomGit API v5,支持分页、JSON 请求体和 GET、POST、PATCH、PUT、DELETE 方法

AI Agent Skills

AtomGit Skills 提供由 ag 驱动的 Codex Skills,覆盖 Issue、Pull Request、CLI 发布和 GitHub 镜像工作流。安装方式和完整清单见该仓库。

安装

npm

npm install -g @hust-open-atom-club/atomgit-cli

Homebrew

安装 Homebrew Core 提供的最新稳定版(推荐):

brew install atomgit-cli

如需跟踪 AtomGit main 最新 commit 的开发快照,可改用项目维护的 Homebrew Tap:

brew install hust-open-atom-club/tap/atomgit-cli

Homebrew Core 面向稳定版,项目 Tap 面向开发快照;两者使用同名 Formula,不能同时安装。区别和切换方法请参阅完整安装指南。

WinGet

winget install HUSTOpenAtomClub.AtomGitCLI

Scoop

scoop bucket add hust-open-atom-club https://github.com/hust-open-atom-club/ScoopBucket
scoop install atomgit-cli

Nix / NixOS

目前仅 nixos-unstable 提供 atomgit-cli,请确保 nixpkgs 指向 unstable;stable 尚未收录。

nix profile install nixpkgs#atomgit-cli

Aur / Archlinux

目前atomgit 已经上传到aur 中,用户可以用yay/paru自行选择从二进制、源码或开发版安装

# 从源码安装(稳定版)
yay -S atomgit-cli
# 二进制安装(稳定版,免编译)
yay -S atomgit-cli-bin
# 开发版安装(跟随 main 分支最新提交)
yay -S atomgit-cli-git

OpenKylin

目前已正式进入 OpenKylin 软件仓库,支持 OpenKylin 2.0 SP2 及 OpenKylin 3.0,最新版本进入 proposed 仓库,待测试验证后推送至 release 仓库。

sudo apt update
sudo apt install atomgit-cli

如果需要安装 proposed 仓库中的最新版本,请参考 安装指南 中的相关说明。

Go

go install atomgit.com/hust-open-atom-club/atomgit-cli/cmd/ag@latest

安装要求、升级方式、AtomGit Release 和源码安装请参阅完整安装指南。

配置

首次使用时运行 ag auth login 完成 OAuth 登录;无浏览器环境(沙箱、容器、CI)可改用 echo "$TOKEN" | ag auth login --with-token 通过已有访问令牌登录。凭据、输出安全和仓库推断参阅配置指南。

使用

运行 ag --help 查看命令概览,或运行 ag <command> --help 查看具体命令的参数。完整示例和说明参阅使用指南,命令索引参阅命令参考。

安装、认证、使用和故障排查中的常见问题请参阅常见问题(FAQ)。

更多文档

API

常规仓库功能使用 AtomGit API v5:https://api.atomgit.com/api/v5。

Actions 运行检查使用独立的 AtomGit API v8:https://api.atomgit.com/api/v8。

参考

License

木兰宽松许可证第2版 (Mulan Permissive Software License, Version 2)

Copyright (c) 2026 HUST OpenAtom Club, AtomGit, and the AtomGit CLI contributors

Releases

Packages

Contributors

Languages