18-Git仓与安全

18-Git仓与安全 is a skill for Claude Code, Codex from xcodethink/open-claude-code-skills. It costs 269 tokens per session (3,743 once invoked), scanned A, original, MIT.

A set of rules for organizing Git repositories and classifying information by sensitivity, from private local work to public open-source code.

In plain words
What is it for?
Use it when creating a repository, deciding who can access it, writing ignore rules or commit checks, rotating tokens, or responding to an accidentally exposed secret.
Why use it?
It reduces the risk of exposing passwords, tokens, financial details, contracts, or other sensitive material through commits and repository access.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/xcodethink/open-claude-code-skills/18-git
Any agent
npx skills add xcodethink/open-claude-code-skills --skill 18-git
Clone the repo
git clone --depth 1 https://github.com/xcodethink/open-claude-code-skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for 18-Git仓与安全

README.md
[![agentmods](https://agentmods.dev/badge/skills/xcodethink/open-claude-code-skills/18-git.svg)](https://agentmods.dev/skills/xcodethink/open-claude-code-skills/18-git)
Your own site
<a href="https://agentmods.dev/skills/xcodethink/open-claude-code-skills/18-git"><img src="https://agentmods.dev/badge/skills/xcodethink/open-claude-code-skills/18-git.svg" alt="Measured on agentmods" height="20"></a>
Per session 269 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,743 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00269 $0.03743
Opus 5 $0.00134 $0.01871
Sonnet 5 $0.00054 $0.00749
Haiku 4.5 $0.00027 $0.00374

Measured 3d ago against content hash 4e2e7466f08b, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

18-Git仓与安全 scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/18-Git仓与安全/SKILL.md · 205 lines

How it starts

The opening of the file, as written. The whole thing — 205 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Git 仓库与安全规范

通用 skill — 所有项目的 Git 仓库分层、信息分级、防泄露规范。 与 17-项目目录标准 配套使用。 与 16-开源发布 互补:本 skill 管"日常 + 闭源", 16 管"对外开源发布"。

4 大执行 checklist(按 tier 分)

本 SKILL.md 是总览 — 具体每个 tier 的可执行 checklist 在子文件:

Tier 子文件 触发场景
本地建设 01-本地仓库建设标准.md 新项目 Day 0 / 每次 commit / 每周维护 / 每季 token 轮换
T1 personal push 02-私人仓库推送标准.md personal private 仓 push 前 / 团队加入触发升级 / 误推 secret 应急
T2 team push 03-团队仓库推送标准.md 付费 Org private 仓 push 前 / PR 流程 / 离职 access 撤销
T2 派生镜像 03b-派生镜像团队仓标准.md 个人账号 <project>-team(不开 Org)/ 加外部协作者 / origin→team 过滤推送 / 审计必扫历史 blob
T3 open source 04-开源仓库推送标准.md 公开仓 release / T2→T3 promotion / 误发开源应急(联用 Skill 16

强制阅读顺序:先读本 SKILL.md(理解 4 级分级 + T0-T3 仓库分层),再按当前场景读对应子文件。

Lifecycle 决策树(避免过度工程化)

                      新项目要建仓
                            │
                            ▼
                 团队人数 ≥ 2?或即将加入?
                       /         \
                     NO           YES
                      │             │
                      ▼             ▼
            [T1 personal lab]   [直接 T2 team org]
              单人快速干活        需 GitHub Pro/Team plan
                  │
                  ├─ 读 17 + 18 sub 01(建结构 + 安全配置)
                  ├─ 读 18 sub 02(每次 push checklist)
                  └─ 不读 / 不需要 sub 03 / sub 04
                  │
                  ▼
              团队第 2 人加入触发?
                   /        \
                 NO           YES
                  │            │
                  ▼            ▼
              留 T1        升级到 T2
                          ├─ 创建 GitHub org
                          ├─ 升级 plan(branch protection 解锁)
                          ├─ T1→T2 promote 内容(用 promote.sh)
                          ├─ 团队 invite 到 T2,不 invite T1
                          └─ 读 18 sub 03
                          │
                          ▼
                      要开源 SDK / CLI?
                          /        \
                        NO           YES
                         │            │
                         ▼            ▼
                     T3 不启用     启用 T3
                                ├─ 决策走 D-Legal-04 流程
                                ├─ 读 18 sub 04 + Skill 16 全套
                                ├─ Pre-publish 9 步审计强制
                                └─ T2→T3 单向 promote(不双向 sync)

Read the full file on GitHub · 205 lines

Files

What ships with it

9 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 205 lines · 269 tokens per session scan A 4e2e7466f08b

Subscribe to this mod's changes

18-Git仓与安全 is a skill published in the GitHub repository xcodethink/open-claude-code-skills (2 stars, last pushed 28d ago), licensed MIT. It adds 269 tokens to every session and 3,743 once invoked, about $0.0013 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

android-finance-spec

Use when generating, reviewing, or refactoring Android Kotlin code for financial apps that require BigDecimal/String precision, RTL/i18n safety, Kotlin style discipline, and "do not reinvent existing project patterns" constraints.

brycegao/android-finance-spec · 48 tokens

elite-engineer

The operating system for elite software engineering in TypeScript, React, and Next.js. Enforces the cognitive models, architecture laws, type-level patterns, component design, visual standards, and performance mandates that separate exceptional software from the ordinary — grounded in named sources (Torvalds…

Kerim-Sabic/elite-engineer · 167 tokens

rulesync

Generates and syncs AI rule configuration files (.cursorrules, CLAUDE.md, copilot-instructions.md) across 20+ coding tools from a single source. Use when syncing AI rules, running rulesync commands, importing or generating rule files, or managing shared AI coding configurations.

dyoshikawa/rulesync · 64 tokens

establishing-project-context

Use when the user asks to establish shared project language, or project work exposes a conflicting, renamed, or deprecated domain term that needs active semantic modeling. Routine small tasks stay on the fast path.

GanyuanRan/Aegis · 45 tokens

autoprompt

Explicit-only useful-first orchestration. Invoke /autoprompt to turn a mission into one executable roadmap, build dependency-safe lanes, and verify the result with independent reviewers. Never infer invocation from ordinary requests. Never resume from leftover artifacts without an explicit resume instruction.

Spielewoy/autoprompt-skill · 56 tokens

loongsuite-pilot-insight

基于 LoongSuite Pilot / AI Coding Agent 日志生成事件洞察、组织洞察、数据质量、研发效能和 AI Native 使用类 SLS 报表时使用;包含 AI Coding 事件表语义,以及团队报表可选的部门维表、deptuser 组织关系、指标口径和公共 CTE,通常与 sls-dashboard-builder 一起使用。.

alibaba/loongsuite-pilot · 91 tokens