pkg / rock Goto Github PK
View Code? Open in Web Editor NEWCreate semantic version tags for your Go packages, search and discover new packages
License: Apache License 2.0
Create semantic version tags for your Go packages, search and discover new packages
License: Apache License 2.0
First of all: nice work! I like that you've made a tool for helping people tagging and releasing stuff.
When I downloaded the code, I couldn't help but notice that the are lots of dependencies for this:
$ go get -v github.com/pkg/rock
github.com/pkg/rock (download)
github.com/blang/semver (download)
github.com/gogits/git (download)
github.com/Unknwon/cae (download)
github.com/mitchellh/go-homedir (download)
github.com/spf13/cobra (download)
github.com/spf13/pflag (download)
github.com/spf13/viper (download)
github.com/fsnotify/fsnotify (download)
github.com/magiconair/properties (download)
github.com/mitchellh/mapstructure (download)
github.com/pelletier/go-toml (download)
github.com/spf13/afero (download)
github.com/spf13/cast (download)
github.com/spf13/jwalterweatherman (download)
Fetching https://gopkg.in/yaml.v2?go-get=1
Parsing meta tags from https://gopkg.in/yaml.v2?go-get=1 (status code 200)
get "gopkg.in/yaml.v2": found meta tag get.metaImport{Prefix:"gopkg.in/yaml.v2", VCS:"git", RepoRoot:"https://gopkg.in/yaml.v2"} at https://gopkg.in/yaml.v2?go-get=1
gopkg.in/yaml.v2 (download)
golang.org/x/sys/unix
github.com/pelletier/go-toml
github.com/magiconair/properties
github.com/mitchellh/go-homedir
github.com/Unknwon/cae
github.com/spf13/pflag
github.com/blang/semver
github.com/mitchellh/mapstructure
github.com/Unknwon/cae/tz
github.com/Unknwon/cae/zip
github.com/spf13/afero/mem
golang.org/x/text/transform
github.com/spf13/cast
golang.org/x/text/unicode/norm
github.com/spf13/jwalterweatherman
gopkg.in/yaml.v2
github.com/fsnotify/fsnotify
github.com/spf13/cobra
github.com/gogits/git
github.com/spf13/afero
github.com/spf13/viper
github.com/pkg/rock/cmd
github.com/pkg/rock
I'm not saying that's wrong, but it seemed like a lot of dependencies for such a small utility. According to go list
there are 136 dependencies in the cmd
directory (where the magic happens):
$ go list -f '{{len .Deps}}' ./cmd
136
So I've wondered if it wouldn't be possible to remove some dependencies, and I've identified that you are using github.com/gogits/git
for all Git related operations but pushing the tag, and I went ahead and did a quick hack to remove that dependency and rely on executing git
with os/exec
: I've managed to remove the dependency and now go list
shows 128
transitive dependencies, not much, but something.
If you are interested I can send a pull request to this repository.
Again, thanks for making this tool.
If a repository has had it's tags packed with git pack-refs
then rock tags
returns nothing (and attempting to create a tag assumes current tag is 0.0.0
)
Appears to be an issue with gogits/git
library (Known issue - Have opened a pull request to attempt to fix the issue)
Issue: gogs/git#27
PR: gogs/git#31
This should not be a duplicate of #3 since I am not using packed tags in http://github.com/hhrutter/pdfcpu but
rock tags
returns an incomplete tag list compared to
git tag -l
and for my checked out pkg/rock it returns an empty list.
Looks like an issue with gogits.
Inspect current against previously tagged version, use the AST to determine if breaking changes, new features, or no features were added. Suggest appropriate release tag bump
"rock search" keeps returning the following for me regardless of any supplied arguments.:
Unmarshaling response.: invalid character 'B' after top-level value
I am on go1.9/linux64 but the same happens on my Mac.
We should use something to manage the project dependencies, dep seems a fitting choice ๐
I have old version 1.0.2 and current 1.1.0
Command rock tag -p
produce wrong version v1.1.3 instead v1.1.1
Existing Tags:
v1.0.1
v1.0.0
v1.1.0
v1.0.2
Creating v1.1.3
Tagged and pushed release v1.1.3
I have managed to bump the wrong revision a couple of times now and I know it is a two liner with git to kill the local and remote tag but I'd love to be able to do this with rock as well.
What happened: Upon trying go get github.com/pkg/rock
received the error message
# github.com/pkg/rock/cmd
cmd/tag.go:23:2: git redeclared as imported package name
previous declaration at cmd/tag.go:21:2
cmd/tag.go:132:17: repo.GetBranchCommitID undefined (type *"github.com/gogits/git".Repository has no field or method GetBranchCommitID)
Expected: A clean result with a $GOPATH/bin/rock
.
Alternatively: If not intending use from master then a compiled binary with the GitHub release.
go env
GOARCH="amd64"
GOBIN=""
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="darwin"
GOOS="darwin"
GOPATH="/[[redacted]]/go"
GORACE=""
GOROOT="/usr/local/Cellar/go/1.9.2/libexec"
GOTOOLDIR="/usr/local/Cellar/go/1.9.2/libexec/pkg/tool/darwin_amd64"
GCCGO="gccgo"
CC="clang"
GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/dd/9lyxqdw14vg7zk1m7_vg0_hh0000gn/T/go-build453521229=/tmp/go-build -gno-record-gcc-switches -fno-common"
CXX="clang++"
CGO_ENABLED="1"
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
os ver
ProductName: Mac OS X
ProductVersion: 10.13.1
BuildVersion: 17B48
like "rc" and "beta"
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.