Skip to content

Commit 39a5dbc

Browse files
author
Nate Smith
authored
Merge pull request cli#102 from github/linux-packages
linux packaging
2 parents a5da699 + 52a1575 commit 39a5dbc

File tree

2 files changed

+45
-2
lines changed

2 files changed

+45
-2
lines changed

.goreleaser.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,18 @@ archives:
2424
format_overrides:
2525
- goos: windows
2626
format: zip
27+
28+
nfpms:
29+
- license: MIT
30+
maintainer: GitHub
31+
homepage: https://github.com/github/gh-cli
32+
bindir: /usr/local
33+
dependencies:
34+
- git
35+
formats:
36+
- deb
37+
- rpm
38+
2739
changelog:
2840
sort: asc
2941
filters:

README.md

Lines changed: 33 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,31 @@ This tool is an endeavor separate from [github/hub](https://github.com/github/hu
88

99
_warning, gh is in a very alpha phase_
1010

11+
## macOS
12+
1113
`brew install github/gh/gh`
1214

13-
That's it. You are now ready to use `gh` on the command line. 🥳
15+
## Debian/Ubuntu Linux
16+
17+
1. Download the latest `.deb` file from the [releases page](https://github.com/github/gh-cli/releases)
18+
2. Install it with `sudo dpkg -i gh_0.2.2_linux_amd64.deb`, changing version number accordingly
19+
20+
_(Uninstall with `sudo apt remove gh`)_
21+
22+
## Fedora/Centos Linux
23+
24+
1. Download the latest `.rpm` file from the [releases page](https://github.com/github/gh-cli/releases)
25+
2. Install it with `sudo yum localinstall gh_0.2.2_linux_amd64.rpm`, changing version number accordingly
26+
27+
_(Uninstall with `sudo yum remove gh`)_
28+
29+
## Other Linux
30+
31+
1. Download the latest `_linux_amd64.tar.gz` file from the [releases page](https://github.com/github/gh-cli/releases)
32+
2. `tar -xvf gh_0.2.2_linux_amd64.tar.gz`, changing version number accordingly
33+
3. Copy the uncompressed `gh` somewhere on your `$PATH` (e.g. `sudo cp gh /usr/local/bin/`)
34+
35+
_(Uninstall with `rm`)_
1436

1537
# Process
1638

@@ -25,4 +47,13 @@ This can all be done from your local terminal.
2547
1. `git tag 'vVERSION_NUMBER' # example git tag 'v0.0.1'`
2648
2. `git push origin vVERSION_NUMBER`
2749
3. Wait a few minutes for the build to run and CI to pass. Look at the [actions tab](https://github.com/github/gh-cli/actions) to check the progress.
28-
4. Go to https://github.com/github/homebrew-gh/releases and look at the release
50+
4. Go to <https://github.com/github/homebrew-gh/releases> and look at the release
51+
52+
# Test a release
53+
54+
A local release can be created for testing without creating anything official on the release page.
55+
56+
1. `git tag 'v6.6.6' # some throwaway version number`
57+
2. `env GH_OAUTH_CLIENT_SECRET=foobar GH_OAUTH_CLIENT_ID=1234 goreleaser --skip-publish --rm-dist`
58+
3. Check and test files in `dist/`
59+
4. `git tag -d v6.6.6 # delete the throwaway tag`

0 commit comments

Comments
 (0)