# git を Homebrew, apk, chocolatey, apt, dnf, MacPorts, Nix, pacman, zypper, scoop, winget でインストール

git のインストール経路、実行ファイル、メタデータ、AI エージェント向けセキュリティノートを確認します。

## インストール

```sh
sudo av install brew:git
```

## エージェント安全性の回答

git can read repository history and mutate source-control state used by agents and humans.

- **認証情報アクセス:** Reads credential helpers, remotes, config, signed keys, and repository-local secret history.
- **リモート変更:** Can push commits, tags, branches, and force updates to remote repositories.
- **公開/成果物リスク:** Can publish source changes and release tags that downstream systems consume.
- **推奨コントロール:** Gate pushes, tag creation, credential fill, and remote rewrites.
- **エージェント利用ガイダンス:** Allow diff/status/log reads; require approval for pushes, credential-helper reads, and destructive history changes.

追加のインストールコマンド:

### macOS

- Homebrew (100%):

```sh
brew install git
```

  証拠: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install git
```

  証拠: MacPorts ports tree: devel/git/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1

### Linux

- apk (92%):

```sh
sudo apk add git
```

  証拠: Alpine Linux edge package indexes: git from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz

- Debian apt (92%):

```sh
sudo apt install git
```

  証拠: Debian stable package indexes: git from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz

- dnf (92%):

```sh
sudo dnf install git
```

  証拠: Fedora Rawhide package metadata: git from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst

- Nix (92%):

```sh
nix profile install nixpkgs#git
```

  証拠: nixpkgs package indexes: pkgs/by-name/gi/git/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

- pacman (92%):

```sh
sudo pacman -S git
```

  証拠: Arch Linux sync databases: git from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz

- zypper (92%):

```sh
sudo zypper install git
```

  証拠: openSUSE Tumbleweed package metadata: git from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst

### Windows

- Chocolatey (92%):

```sh
choco install git
```

  証拠: Chocolatey community package catalog: git from http://community.chocolatey.org/api/v2/Packages?$filter=IsLatestVersion&$select=Id&$top=1000&$skiptoken='11','fusioninventory-agent'

- Scoop (92%):

```sh
scoop install main/git
```

  証拠: Scoop official bucket manifest trees: bucket/git.json from https://api.github.com/repos/ScoopInstaller/Main/git/trees/master?recursive=1

- winget (92%):

```sh
winget install --id DuckStudio.ChineseGit -e
```

  証拠: Windows Package Manager source index: DuckStudio.ChineseGit from https://cdn.winget.microsoft.com/cache/source.msix

## パッケージ情報

- **パッケージキー:** brew:git
- **パッケージマネージャ:** Homebrew
- **バージョン:** 2.55.0
- **ソース概要:** Distributed revision control system
- **ホームページ:** <https://git-scm.com>
- **リポジトリ:** <https://github.com/git/git>
- **最終更新:** 2026-06-29T20:54:53Z
- **生成日時:** 2026-08-03T19:37:03+00:00

## 実行可能ファイル

- git (エイリアス)
- git-cvsserver (エイリアス)
- git-receive-pack (エイリアス)
- git-shell (エイリアス)
- git-upload-archive (エイリアス)
- git-upload-pack (エイリアス)
- scalar (エイリアス)

## インストール挙動

- Bottle: 利用不可

## バージョンと鮮度

- ページ生成日: 2026-08-03
- マネージャ版: 2.55.0
## プロジェクトの歴史と使われ方

Git is the distributed version-control system created for Linux kernel development and later generalized into the default source-control substrate for much of software development. Its command-line interface, repository format, protocol family, and ecosystem of hosting services define how many projects exchange code.

### プロジェクトの歴史

Git began in 2005 after the Linux kernel community lost access to the proprietary BitKeeper workflow it had been using. Linus Torvalds wrote the original implementation to support Linux-scale development, emphasizing speed, integrity, distributed operation, and cheap branching.

The design departed from centralized version-control systems by making every clone a full repository with local history and branch operations. That choice made offline work, fork-based development, and patch exchange natural rather than exceptional.

After its Linux origin, Git evolved into a broadly portable tool with a large manual set, porcelain commands for everyday work, and plumbing commands for scripts and higher-level tools. The kernel.org repository remains the canonical upstream source location, while git-scm.com provides the public documentation hub.

### 採用の歴史

Git's adoption accelerated with distributed open source development and the rise of Git hosting services such as GitHub, GitLab, and related forges. The official Git site characterizes the core project as a command-line tool surrounded by hosting services, graphical clients, editor integrations, and other command-line helpers.

By the early 2010s, Git had moved from a Linux-kernel tool into the common denominator for open source collaboration, commercial software teams, CI systems, package ecosystems, and code review platforms. Its repository model also became the foundation for workflows outside source code, including documentation and data-adjacent projects.

### 使われ方

Practitioners use Git to initialize or clone repositories, stage and commit changes, branch and merge work, inspect history, exchange commits through remotes, and recover earlier states. Its local-first model makes common commands fast because most history and metadata are on the developer's machine.

Teams layer policy on top of Git through protected branches, pull requests, signed commits, release tags, submodules, worktrees, hooks, and CI triggers. The same executable serves both interactive daily work and automation in release scripts, package recipes, deployment systems, and source archives.

### パッケージ好きにとっての重要性

Git is one of the central dependencies of package-manager culture. Formulae, ports, distro source packages, language registries, and build systems routinely fetch from Git repositories, pin commits or tags, generate source archives, and use Git metadata to derive versions.

Its significance also comes from its stability as an interchange format. Even tools that wrap Git, avoid the Git CLI, or store files elsewhere usually need to speak in Git concepts: commits, refs, remotes, branches, tags, diffs, and patches.

### タイムライン

- 2005: Git was created for Linux kernel development after the BitKeeper transition.
- 2005: Early Git releases established the distributed repository model.
- 2010s: Hosted Git forges and pull-request workflows made Git the dominant version-control system for many developer communities.
- 2020s: Git remained a base dependency for package managers, CI, source archives, and developer tools.

### Related projects

- Linux kernel development drove Git's original requirements.
- GitHub, GitLab, Gitea, Forgejo, and other forges build hosted collaboration around Git repositories.
- Git LFS and Git Xet extend Git workflows for large-file storage.
- Scalar, included with Git packages, targets very large repository workflows.

### ソース

- <https://git-scm.com/about>
- <https://git-scm.com/book/en/v2/Getting-Started-A-Short-History-of-Git>
- <https://git-scm.com/docs>
- <https://git-scm.com/docs/git>
- <https://git.kernel.org/pub/scm/git/git.git>


## セキュリティノート

doc example: broad file and network tool.

- **Geiger リスク:** blue / 高
- doc example: broad file and network tool
- **承認ゲートルール:** 6


## Configuration and credential file locations

These source-backed paths show where this package keeps local settings or durable credentials. Automic Vault can use them as review targets for secret scanning, migration, and command approval.


## Credential files

- Unix: ~/.git-credentials
## 他のパッケージマネージャ記録

- Debian apt - git - 1:2.47.3-0+deb13u1: normalized package name match | Debian stable package indexes: git from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | fast, scalable, distributed revision control system | https://git-scm.com/
- Debian apt - git-all - 1:2.47.3-0+deb13u1: normalized package name match | Debian stable package indexes: git-all from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | fast, scalable, distributed revision control system (all subpackages) | https://git-scm.com/
- Debian apt - git-cvs - 1:2.47.3-0+deb13u1: normalized package name match | Debian stable package indexes: git-cvs from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | fast, scalable, distributed revision control system (cvs interoperability) | https://git-scm.com/
- Debian apt - git-doc - 1:2.47.3-0+deb13u1: normalized package name match | Debian stable package indexes: git-doc from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | fast, scalable, distributed revision control system (documentation) | https://git-scm.com/
- Debian apt - git-email - 1:2.47.3-0+deb13u1: normalized package name match | Debian stable package indexes: git-email from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | fast, scalable, distributed revision control system (email add-on) | https://git-scm.com/
- Debian apt - git-gui - 1:2.47.3-0+deb13u1: normalized package name match | Debian stable package indexes: git-gui from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | fast, scalable, distributed revision control system (GUI) | https://git-scm.com/
- Debian apt - git-man - 1:2.47.3-0+deb13u1: normalized package name match | Debian stable package indexes: git-man from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | fast, scalable, distributed revision control system (manual pages) | https://git-scm.com/
- Debian apt - git-mediawiki - 1:2.47.3-0+deb13u1: normalized package name match | Debian stable package indexes: git-mediawiki from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | fast, scalable, distributed revision control system (MediaWiki remote helper) | https://git-scm.com/
- Debian apt - git-svn - 1:2.47.3-0+deb13u1: normalized package name match | Debian stable package indexes: git-svn from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | fast, scalable, distributed revision control system (svn interoperability) | https://git-scm.com/
- Debian apt - gitk - 1:2.47.3-0+deb13u1: normalized package name match | Debian stable package indexes: gitk from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | fast, scalable, distributed revision control system (revision tree visualizer) | https://git-scm.com/
- Debian apt - gitweb - 1:2.47.3-0+deb13u1: normalized package name match | Debian stable package indexes: gitweb from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | fast, scalable, distributed revision control system (web interface) | https://git-scm.com/
- Nix - git: normalized package name match | nixpkgs package indexes: pkgs/by-name/gi/git/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Ubuntu apt - git - 1:2.43.0-1ubuntu7: normalized package name match | Ubuntu 24.04 LTS package indexes: git from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | fast, scalable, distributed revision control system | https://git-scm.com/
- Ubuntu apt - git-all - 1:2.43.0-1ubuntu7: normalized package name match | Ubuntu 24.04 LTS package indexes: git-all from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | fast, scalable, distributed revision control system (all subpackages) | https://git-scm.com/
- Ubuntu apt - git-cvs - 1:2.43.0-1ubuntu7: normalized package name match | Ubuntu 24.04 LTS package indexes: git-cvs from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | fast, scalable, distributed revision control system (cvs interoperability) | https://git-scm.com/
- Ubuntu apt - git-daemon-run - 1:2.43.0-1ubuntu7: normalized package name match | Ubuntu 24.04 LTS package indexes: git-daemon-run from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | fast, scalable, distributed revision control system (git-daemon service) | https://git-scm.com/


## Combined YAML source

View the package source record on GitHub. [combined/git.yml](https://github.com/mxcl/pkgdb/blob/main/combined/git.yml)


## ソース

- pkg.so package database
- Geiger risk classifier
- approval-gate seed metadata
- curated configuration and credential file locations
- curated package history
- pkgdb category and tag curation
- external package-manager database matches
- cross-ecosystem install command graph
- curated agent safety answer
