Skip to content

Commit 2cfcc46

Browse files
author
udhos
committed
Recipe for building with Go Modules.
1 parent 42e7721 commit 2cfcc46

File tree

2 files changed

+21
-2
lines changed

2 files changed

+21
-2
lines changed

README.md

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,25 @@ Inspired by [Httpie](https://github.com/jakubroztocil/httpie). Thanks to the aut
3939

4040
## Installation
4141

42+
### Install with Modules - Go 1.11 or higher
43+
44+
If you only want to install the `bat` tool:
45+
4246
go get -u github.com/astaxie/bat
43-
44-
make sure the `$GOPATH/bin` is added into `$PATH`
47+
48+
If you want a mutable copy of source code:
49+
50+
git clone https://github.com/astaxie/bat ;# clone outside of GOPATH
51+
cd bat
52+
go install
53+
54+
Make sure the `~/go/bin` is added into `$PATH`.
55+
56+
### Install without Modules - Before Go 1.11
57+
58+
go get -u github.com/astaxie/bat
59+
60+
Make sure the `$GOPATH/bin` is added into `$PATH`.
4561

4662
## Usage
4763

go.mod

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
module github.com/astaxie/bat
2+
3+
go 1.12

0 commit comments

Comments
 (0)