Skip to content

Commit 076a811

Browse files
committed
chore(readme): update readme
1 parent d480265 commit 076a811

File tree

1 file changed

+23
-9
lines changed

1 file changed

+23
-9
lines changed

README.md

Lines changed: 23 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -15,21 +15,29 @@
1515

1616
## Introduction
1717

18-
The purpose of this package is to extract some git related information (all files sha, also commits sha) from your hosted source version control system
18+
The purpose of `src-fingerprint` is to provide an easy way to extract git related information (namely all files sha of a repository) from your hosted source version control system.
1919

20-
It supports 3 main on premise version control service:
20+
This util supports 3 main version control systems:
2121

22-
- GitHub Enterprise
22+
- GitHub and GitHub Enterprise
2323
- Gitlab CE and EE
2424
- Bitbucket
2525

2626
## Install
2727

2828
### Pre-compiled executables
2929

30-
Get them [here](http://github.com/gitguardian/src-fingerprint/releases).
30+
Get the executables [here](http://github.com/gitguardian/src-fingerprint/releases).
3131

32-
### Source
32+
### Using Homebrew
33+
34+
If you're using [Homebrew](https://brew.sh/index_fr) you can add GitGuardian's tap and then install src-fingerprint. Just run the following commands :
35+
```shell
36+
brew tap gitguardian/tap
37+
brew install src-fingerprint
38+
```
39+
40+
### From the sources
3341

3442
You need `go` installed and `GOBIN` in your `PATH`. Once that is done, run the
3543
command:
@@ -58,26 +66,32 @@ $ go get -u github.com/gitguardian/src-fingerprint/cmd/src-fingerprint
5866

5967
## Compute my fileshas
6068

69+
### General information
70+
The output format can be chosen between `jsonl`, `json`, `gzip-jsonl` and `gzip-json` with the option `--export-format`.
71+
The default format is `jsonl`, but if you want to minimize the size of the output file choose `gzip-jsonl`.
72+
Also, note that if you were to download fileshas for repositories of a big organization, `src-fingerprint` has a limit to process no more than 100
73+
repositories. You can override this limit with the option `--limit`, a limit of 0 will process all repos of the organization.
74+
6175
### GitHub
6276

6377
1. Export all file SHAs from a GitHub Org with private repositories to a file with logs:
6478

6579
```sh
66-
env VCS_TOKEN="<token>" src-fingerprint -v --output fileshas_collected.json --provider github --object GitGuardian
80+
env VCS_TOKEN="<token>" src-fingerprint -v --export-format gzip-jsonl --output fileshas_collected.jsonl.gz --provider github --object GitGuardian
6781
```
6882

6983
2. Export all file SHAs of every repository the user can access to `stdout`:
7084

7185
```sh
72-
env VCS_TOKEN="<token>" src-fingerprint -v --provider github GitGuardian
86+
env VCS_TOKEN="<token>" src-fingerprint -v --provider github
7387
```
7488

7589
### GitLab
7690

7791
1. Export all file SHAs from a GitLab group with private projects to a file with logs:
7892

7993
```sh
80-
env VCS_TOKEN="<token>" src-fingerprint -v --output fileshas_collected.json --provider gitlab --object "GitGuardian-dev-group"
94+
env VCS_TOKEN="<token>" src-fingerprint -v --export-format gzip-jsonl --output fileshas_collected.jsonl.gz --provider gitlab --object "GitGuardian-dev-group"
8195
```
8296

8397
2. Export all file SHAs of every project the user can access to `stdout`:
@@ -93,7 +107,7 @@ env VCS_TOKEN="<token>" src-fingerprint -v --provider gitlab
93107
1. Export all file SHAs from a Bitbucket project with private repository to a file with logs:
94108

95109
```sh
96-
env VCS_TOKEN="<token>" src-fingerprint -v --output fileshas_collected.json --provider bitbucket --object "GitGuardian Project"
110+
env VCS_TOKEN="<token>" src-fingerprint -v --export-format gzip-jsonl --output fileshas_collected.jsonl.gz --provider bitbucket --object "GitGuardian Project"
97111
```
98112

99113
2. Export all file SHAs of every repository the user can access to `stdout`:

0 commit comments

Comments
 (0)