Skip to content

Commit 9f7124c

Browse files
committed
add low level commands
1 parent 00909c3 commit 9f7124c

File tree

1 file changed

+32
-2
lines changed

1 file changed

+32
-2
lines changed

README.md

+32-2
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,9 @@ GOSPACE_PKG=storj.io/storj
2424
GOSPACE_REPO=git@github.com:storj/storj.git
2525
```
2626

27-
First time you should run:
27+
## Setup
28+
29+
First time when setting up your local system.
2830

2931
```
3032
gospace setup
@@ -37,6 +39,8 @@ gospace setup
3739
3. Run `GO111MODULE=on go mod vendor` inside `$GOSPACE_ROOT/src/$GOSPACE_PKG` folder. This downloads all dependencies into vendor directory.
3840
4. Moves all vendored directories to `$GOSPACE_ROOT/src`.
3941

42+
## Updating
43+
4044
Every time go.mod changes, you should run:
4145

4246
```
@@ -47,4 +51,30 @@ gospace update
4751

4852
1. Delete all non-repository directories in `$GOSPACE_ROOT/src`, effectively deleting all vendored directories. Unless you have placed something manually, which is also deleted.
4953
2. Run `GO111MODULE=on go mod vendor` inside `$GOSPACE_ROOT/src/$GOSPACE_PKG` folder. This downloads all dependencies into vendor directory.
50-
3. Moves all vendored directories to `$GOSPACE_ROOT/src`.
54+
3. Moves all vendored directories to `$GOSPACE_ROOT/src`.
55+
56+
## Low-level commands
57+
58+
To calculate hash of the `go.mod` and `go.sum` file:
59+
60+
```
61+
gospace hash
62+
```
63+
64+
To download dependencies and zip vendor folder:
65+
66+
```
67+
gospace zip-vendor vendor.zip
68+
```
69+
70+
To unzip a vendor directory:
71+
72+
```
73+
gospace unzip-vendor vendor.zip
74+
```
75+
76+
To flatten vendor directory:
77+
78+
```
79+
gospace flatten-vendor
80+
```

0 commit comments

Comments
 (0)