2020-12-15 15:49:51 +00:00
|
|
|
---
|
|
|
|
layout: default
|
|
|
|
---
|
|
|
|
|
|
|
|
# Installation
|
|
|
|
|
|
|
|
## Dependencies
|
|
|
|
|
|
|
|
`git-secret` relies on two dependencies: `git` and `gpg`. Download and install them before using this project. `git-secret` is tested to work with:
|
|
|
|
|
2021-05-03 14:23:54 +00:00
|
|
|
```
|
|
|
|
git version 2.7.0
|
|
|
|
gpg (GnuPG) 1.4.20
|
|
|
|
```
|
2020-12-15 15:49:51 +00:00
|
|
|
|
|
|
|
## Supported platforms
|
|
|
|
|
2022-05-07 14:23:20 +00:00
|
|
|
`git-secret` is tested with `Mac OS X` >= 10.9, `Ubuntu` >= 14.04, `Debian` >= 8.3,
|
2022-06-17 18:31:41 +00:00
|
|
|
`Fedora` / `Rocky Linux` / `AlmaLinux`, `FreeBSD`, and `Windows` >= 10 using `WSL`.
|
2022-04-24 13:47:25 +00:00
|
|
|
You can check the full list of automated test platforms
|
|
|
|
[here](https://github.com/sobolevn/git-secret/blob/master/.github/workflows/test.yml).
|
|
|
|
|
2022-05-07 14:23:20 +00:00
|
|
|
We are always interested in getting `git-secret` working and tested on additional systems.
|
2022-04-24 13:47:25 +00:00
|
|
|
If you get `git-secret` working on a new system and the tests pass for you,
|
2022-07-20 06:32:23 +00:00
|
|
|
you can add a GitHub Action to test your platform to that file.
|
2022-04-24 13:47:25 +00:00
|
|
|
Also we welcome improvements to tests or `git-secret` code for any platform.
|
2020-12-15 15:49:51 +00:00
|
|
|
|
|
|
|
## Installation process
|
|
|
|
|
2022-04-24 13:47:25 +00:00
|
|
|
There are several ways to install `git-secret`, depending on your OS and distribution.
|
2022-04-24 15:15:14 +00:00
|
|
|
They generally all have different installation processes, so we only go into
|
|
|
|
a short explanation of each.
|
2022-04-24 14:09:14 +00:00
|
|
|
(We welcome documentation improvements.)
|
2020-12-15 15:49:51 +00:00
|
|
|
|
|
|
|
---
|
|
|
|
|
2022-04-24 15:15:14 +00:00
|
|
|
### Mac OS X / Homebrew
|
2020-12-15 15:49:51 +00:00
|
|
|
|
2022-04-24 13:47:25 +00:00
|
|
|
This is a packaging system for OSX. To install `git-secret` on OSX, you can install
|
|
|
|
`homebrew` and then use:
|
|
|
|
|
2022-04-24 14:09:14 +00:00
|
|
|
```bash
|
|
|
|
brew install git-secret
|
|
|
|
````
|
2020-12-15 15:49:51 +00:00
|
|
|
|
|
|
|
---
|
|
|
|
|
2022-04-24 15:15:14 +00:00
|
|
|
### Debian-Type Systems / `deb` package
|
2020-12-15 15:49:51 +00:00
|
|
|
|
2022-04-24 13:47:25 +00:00
|
|
|
`deb` is a packaging system for [Debian](https://www.debian.org/) and related linux
|
|
|
|
distributions.
|
|
|
|
|
2021-05-04 19:06:40 +00:00
|
|
|
You can find the `deb` repository [here](https://gitsecret.jfrog.io/artifactory/git-secret-deb/).
|
2021-05-04 09:26:39 +00:00
|
|
|
Pre-requirements: make sure you have installed `apt-transport-https` and `ca-certificates`
|
2020-12-15 15:49:51 +00:00
|
|
|
|
|
|
|
```bash
|
2021-05-05 12:59:28 +00:00
|
|
|
{% include install-deb.sh %}
|
2020-12-15 15:49:51 +00:00
|
|
|
```
|
|
|
|
|
|
|
|
---
|
|
|
|
|
2022-04-24 15:15:14 +00:00
|
|
|
### Red Hat Systems / `rpm` package
|
2020-12-15 15:49:51 +00:00
|
|
|
|
2022-04-24 13:47:25 +00:00
|
|
|
`rpm` is a packaging system for Fedora, CentOS, and other Red Hat based linux distributions.
|
2021-05-04 19:06:40 +00:00
|
|
|
You can find the `rpm` repository [here](https://gitsecret.jfrog.io/artifactory/git-secret-rpm/).
|
2020-12-15 15:49:51 +00:00
|
|
|
|
|
|
|
```bash
|
2021-05-05 12:59:28 +00:00
|
|
|
{% include install-rpm.sh %}
|
2020-12-15 15:49:51 +00:00
|
|
|
```
|
|
|
|
|
2021-05-05 12:59:28 +00:00
|
|
|
---
|
|
|
|
|
2022-04-24 15:15:14 +00:00
|
|
|
### Alpine Systems / `apk` package
|
2021-05-06 10:16:48 +00:00
|
|
|
|
2022-04-24 14:03:26 +00:00
|
|
|
`apk` is a packaging system for Alpine.
|
|
|
|
You can find the `apk` `git-secret` packaging
|
|
|
|
[here](https://gitsecret.jfrog.io/artifactory/git-secret-apk/),
|
|
|
|
and you can see a list of supported architectures
|
|
|
|
[here](https://github.com/sobolevn/git-secret/blob/master/utils/apk/meta.sh)
|
2021-05-06 10:16:48 +00:00
|
|
|
|
|
|
|
```bash
|
|
|
|
{% include install-apk.sh %}
|
|
|
|
```
|
|
|
|
|
|
|
|
---
|
|
|
|
|
2022-04-24 15:15:14 +00:00
|
|
|
### Arch Linux / `PKGBUILD` or `AUR`
|
2020-12-15 15:49:51 +00:00
|
|
|
|
|
|
|
The _Arch_ way to install git-secret is to use the directions for
|
|
|
|
"Installing Packages" at [Arch User Repository Documentation](https://wiki.archlinux.org/index.php/Arch_User_Repository#Installing_packages)
|
|
|
|
along with the `PKGBUILD` file from the [git-secret Arch Linux Package](https://aur.archlinux.org/packages/git-secret/)
|
|
|
|
|
2021-05-03 14:23:54 +00:00
|
|
|
You can also install from the [AUR](https://aur.archlinux.org/) using your helper of choice by
|
2020-12-15 15:49:51 +00:00
|
|
|
installing the package `git-secret`, for example using [yay](https://github.com/Jguer/yay)
|
|
|
|
|
|
|
|
```bash
|
|
|
|
yay -S git-secret
|
|
|
|
```
|
|
|
|
|
|
|
|
---
|
|
|
|
|
2022-04-24 15:15:14 +00:00
|
|
|
### Windows / `WSL`, `Cygwin`, `MSYS`, or `Mingw-w64`
|
2022-04-24 13:48:30 +00:00
|
|
|
|
|
|
|
`git-secret` depends on many unix tools and features that Windows systems do not usually
|
|
|
|
include by default. Therefore to get `git-secret` running on Windows you have to
|
2022-04-24 14:09:46 +00:00
|
|
|
install these tools, probably using one of the toolkits described below.
|
2022-04-24 15:15:14 +00:00
|
|
|
Each has a different install and setup process. There may also be other
|
|
|
|
ways to install the unix prerequisites on Windows.
|
2022-04-24 13:48:30 +00:00
|
|
|
|
2022-04-24 15:15:14 +00:00
|
|
|
Once the prerequisite unix tools are installed,
|
2022-04-24 14:09:14 +00:00
|
|
|
you can use the Manual Installation instructions below to
|
2022-04-24 13:48:30 +00:00
|
|
|
manually install `git-secret` (see below).
|
|
|
|
|
2022-04-24 15:15:14 +00:00
|
|
|
Some ways to install the required unix tools on windows include
|
|
|
|
WSL, CYGWIN, MSYS, and Mingw-w64
|
|
|
|
(internally, these tools may share some components).
|
2022-04-24 13:48:30 +00:00
|
|
|
|
2022-04-24 15:15:14 +00:00
|
|
|
Documenting how each is installed and used is beyond the scope of this document,
|
2022-04-24 13:48:30 +00:00
|
|
|
so we will cover the topic in broad strokes. Improvements to this documentation
|
|
|
|
(or any other git-secret documentation) are welcome.
|
|
|
|
|
|
|
|
Again, after you install the unix tools needed, you can install
|
|
|
|
`git-secret` on windows using the `Manual Installation` steps below.
|
|
|
|
|
|
|
|
#### WSL
|
|
|
|
|
|
|
|
Perhaps the easiest way to get `git-secret` operating on windows is using `WSL`
|
|
|
|
(if your system supports it).
|
|
|
|
Here are instructions to install [WSL](https://docs.microsoft.com/en-us/windows/wsl/install)
|
2022-04-24 15:15:14 +00:00
|
|
|
You'll need to install these additional packages: `gnupg`, `make`, `man`, `git`, `gawk`, `file`.
|
2022-04-24 13:48:30 +00:00
|
|
|
|
|
|
|
We have successfully set up automated testing of `git-secret` on `WSL`,
|
|
|
|
so we are confident this method works.
|
|
|
|
|
|
|
|
#### Mingw-w64
|
|
|
|
|
2022-04-24 15:15:14 +00:00
|
|
|
Another way to install the prerequisites for `git-secret` on Windows is to use
|
2022-04-24 13:48:30 +00:00
|
|
|
[Mingw-w64](https://www.mingw-w64.org/) and install the needed packages.
|
2022-04-24 14:01:27 +00:00
|
|
|
By default, the `Mingw-w64` installation will be saved to `C:\msys64`. You'll need to
|
|
|
|
install `make` and probably other tools such as `gnupg`, `make`, `man`, `git`, and `gawk`.
|
2022-04-24 15:15:14 +00:00
|
|
|
(This list might not be complete).
|
2022-04-24 13:48:30 +00:00
|
|
|
|
|
|
|
#### MSYS and Cygwin
|
|
|
|
|
2022-04-24 15:15:14 +00:00
|
|
|
`git-secret` also works with [MSYS](https://www.msys2.org/)
|
|
|
|
and [Cygwin](https://www.cygwin.com/), and we have gotten _most_ of the way to getting
|
2022-04-24 14:01:27 +00:00
|
|
|
`git-secret`'s self-tests running on these setups with Windows (see
|
2022-04-25 16:47:58 +00:00
|
|
|
[windows-related issues](https://github.com/sobolevn/git-secret/issues?q=is%3Aissue+is%3Aopen+windows)).
|
2022-04-24 14:01:27 +00:00
|
|
|
|
2022-04-24 15:15:14 +00:00
|
|
|
We welcome contributions to `git-secret` and its documentation .
|
2022-04-24 13:48:30 +00:00
|
|
|
|
|
|
|
---
|
|
|
|
|
|
|
|
### Manual Installation
|
2020-12-15 15:49:51 +00:00
|
|
|
|
|
|
|
```bash
|
|
|
|
git clone https://github.com/sobolevn/git-secret.git git-secret
|
|
|
|
cd git-secret && make build
|
|
|
|
PREFIX="/usr/local" make install
|
|
|
|
```
|
|
|
|
|
2022-04-24 15:15:14 +00:00
|
|
|
Note that you can change `PREFIX` to be any directory you subsequently include in in your `PATH`
|
2022-07-20 06:32:23 +00:00
|
|
|
environment variable. We generally recommend you stick to the default
|
2022-04-24 13:48:30 +00:00
|
|
|
install locations for simplicity, but if you know what you're doing you are welcome to change it.
|
2022-04-22 19:47:44 +00:00
|
|
|
|