Skip to content

Commit ab803e2

Browse files
committed
add installation instructions in a new installation.md file
1 parent b5eba28 commit ab803e2

3 files changed

Lines changed: 71 additions & 21 deletions

File tree

content/_index.md

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,20 +15,30 @@ layout: hextra-home
1515
{{< /hextra/hero-subtitle >}}
1616
</div>
1717

18-
<div class="hx:mb-6">
18+
<div class="hx:mb-6 hx:flex hx:gap-4">
1919
{{< hextra/hero-button text="Get Started" link="docs/getting-started" >}}
20+
<a href="docs/installation" class="not-prose hx:font-medium hx:cursor-pointer hx:px-6 hx:py-3 hx:rounded-full hx:text-center hx:inline-block hx:border hx:border-gray-300 hx:dark:border-neutral-700 hx:hover:bg-gray-100 hx:dark:hover:bg-neutral-800 hx:transition-all hx:ease-in hx:duration-200">Installation</a>
2021
</div>
2122

2223
<div class="hx:mt-6"></div>
2324

2425
Your lockfile shows what dependencies you have, but not how you got here. Running `git log Gemfile.lock` produces noise that no one reads. git-pkgs walks through your git history and builds a SQLite database so you can ask: when did we add this? who added it? what changed between releases? has anyone touched this in the last year?
2526

2627
```bash
27-
git pkgs init # index your history (one-time)
28+
git pkgs init # analyze history (one-time)
29+
git pkgs list # show current dependencies
30+
git pkgs stats # see overview
2831
git pkgs blame # who added each dependency
29-
git pkgs history rails # when was this package changed?
30-
git pkgs why express # why was this added?
31-
git pkgs diff main..feature # what changed between branches?
32+
git pkgs history # all dependency changes over time
33+
git pkgs history rails # track a specific package
34+
git pkgs why rails # why was this added?
35+
git pkgs diff --from=HEAD~10 # what changed recently?
36+
git pkgs diff --from=main --to=feature # compare branches
37+
git pkgs vulns # scan for known CVEs
38+
git pkgs vulns blame # who introduced each vulnerability
39+
git pkgs outdated # find packages with newer versions
40+
git pkgs update # update all dependencies
41+
git pkgs add lodash # add a package
3242
```
3343

3444
The database lives in `.git/pkgs.sqlite3` and stays current through git hooks. Core commands work entirely offline with no network access.

content/docs/getting-started.md

Lines changed: 1 addition & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -3,22 +3,7 @@ title: Getting Started
33
weight: 10
44
---
55

6-
## Installation
7-
8-
Install with Homebrew:
9-
10-
```bash
11-
brew tap git-pkgs/git-pkgs
12-
brew install git-pkgs
13-
```
14-
15-
Or download a binary from the [releases page](https://github.com/git-pkgs/git-pkgs/releases).
16-
17-
Or build from source:
18-
19-
```bash
20-
go install github.com/git-pkgs/git-pkgs@latest
21-
```
6+
See [Installation](/docs/installation) for setup instructions.
227

238
## Quick start
249

content/docs/installation.md

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
---
2+
title: Installation
3+
weight: 5
4+
---
5+
6+
## Homebrew
7+
8+
```bash
9+
brew tap git-pkgs/git-pkgs
10+
brew install git-pkgs
11+
```
12+
13+
## Download binary
14+
15+
Download a prebuilt binary from the [releases page](https://github.com/git-pkgs/git-pkgs/releases).
16+
17+
Binaries are available for:
18+
- macOS (Intel and Apple Silicon)
19+
- Linux (amd64 and arm64)
20+
- Windows (amd64)
21+
22+
## Build from source
23+
24+
Requires Go 1.22 or later.
25+
26+
```bash
27+
go install github.com/git-pkgs/git-pkgs@latest
28+
```
29+
30+
## Verify installation
31+
32+
```bash
33+
git pkgs version
34+
```
35+
36+
## Shell completions
37+
38+
Generate completions for your shell:
39+
40+
```bash
41+
git pkgs completion bash > /etc/bash_completion.d/git-pkgs
42+
git pkgs completion zsh > "${fpath[1]}/_git-pkgs"
43+
git pkgs completion fish > ~/.config/fish/completions/git-pkgs.fish
44+
```
45+
46+
## Next steps
47+
48+
Initialize git-pkgs in a repository:
49+
50+
```bash
51+
cd your-repo
52+
git pkgs init
53+
```
54+
55+
See [Getting Started](/docs/getting-started) for a walkthrough of the main commands.

0 commit comments

Comments
 (0)