https://github.com/fullstorydev/gorepoman
golang tool for managing golang dependencies in a monorepo. Super powered `go get`.
https://github.com/fullstorydev/gorepoman
Last synced: about 1 year ago
JSON representation
golang tool for managing golang dependencies in a monorepo. Super powered `go get`.
- Host: GitHub
- URL: https://github.com/fullstorydev/gorepoman
- Owner: fullstorydev
- License: apache-2.0
- Created: 2017-07-06T17:15:37.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2024-02-22T13:52:40.000Z (over 2 years ago)
- Last Synced: 2024-06-20T06:39:40.143Z (almost 2 years ago)
- Language: Go
- Homepage:
- Size: 34.2 KB
- Stars: 14
- Watchers: 9
- Forks: 2
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
**Deprecation Notice**
As of February 22nd, 2024, this repository will no longer have any maintenance performed, but will remain published in its current form for the time being. Please be sure to consider this when utilizing any of the information & code found within.
# gorepoman
`gorepoman` helps you easily manage and version control go dependencies.
Do you use open-source golang libraries? Do you struggle to track and manage versions, update stale
dependencies, and make custom edits as needed? Do you find the existing tool options somewhat lacking (git submodule, go get,
various go vendoring tools)?
`gorepoman` may be just what you need! `gorepoman` is a super-powered wrapper around `go get` that maintains a
version-controlled JSON manifest. The manifest contains the git SHAs associated with every managed package.
## Quick start demo
```bash
mkdir demo
cd demo
git init
export GOPATH=`pwd`
# bootstrap gorepoman with go get
go get github.com/fullstorydev/gorepoman/...
ls ./bin/gorepoman
# now that we're bootstrapped, nuke the source we fetched with `go get`, and re-fetch gorepoman using gorepoman!
rm -rf src/github.com/pkg/errors github.com/fullstorydev/gorepoman
./bin/gorepoman fetch github.com/fullstorydev/gorepoman
# gorepoman automatically git adds its work, commit the result
git status
git commit -m "gorepoman fetch github.com/fullstorydev/gorepoman"
```
## Subcommands
| subcommand | desc |
| ---------------------------------------- | ------------------------------------------------------------ |
| `gorepoman fetch ` | Fetch the specified dep |
| `gorepoman update ` | Update the specified dep |
| `gorepoman delete ` | Delete the specified dep |
| `gorepoman list` | List all managed deps |
| `gorepoman list stale` | List all out-of-date deps |
| `gorepoman list changed` | List all deps with local changes |
| `gorepoman reconcile [cancel\|done]` | (advanced) Reconcile a locally-changed dep with the upstream |
`` is e.g. 'github.com/pkg/errors'
## Features
- Quickly fetch new depedencies you need and version control them.
- Quickly list stale dependencies, and easily update.
- Transition gradually! `gorepoman` manages only the deps it has added. You don't need to go through and
re-fetch all your go deps on day 1.
- If you've made local changes to one of your deps, advanced `reconcile` mode exports your dep into a real
(external) git repo, so you can easily merge in upstream changes or submit PRs / patches upstream.
- The generated manifest file is sorted and formatted for consistent and easy diff / merge.
## Caveats
- `gorepoman` is git-centric; not only must you use git yourself, but gorepoman can only manage third-party dependencies
that are also git. (This is almost never a problem in practice: everyone uses git!)