23 lines
474 B
Markdown
23 lines
474 B
Markdown
# clone
|
|
|
|
Clone projects into a common GOPATH-like structure.
|
|
|
|
Uses the base path (in order of preference):
|
|
- `$(CLONE_DIR)`
|
|
- `$(UserHomeDir)/code`
|
|
- [$(UserHomeDir)](https://pkg.go.dev/os#UserHomeDir)
|
|
|
|
```shell
|
|
clone git.jojodev.com/jolheiser/clone.git
|
|
```
|
|
by default, on a Linux machine, would clone to `/home/<user>/code/git.jojodev.com/jolheiser/clone`
|
|
|
|
To `cd` into a newly cloned (or initialized) project:
|
|
|
|
```shell
|
|
cd $(clone --last)
|
|
```
|
|
|
|
## License
|
|
|
|
[MIT](LICENSE) |