Fix extraction of tag name from commit ref to handle /
Previously, tags with a `/` character were not correctly handled because `filepath.Base` was used. This would return the last element of path. This change allows for tags like `test/v1.2.3` to work properly by trimming the `refs/tags/` prefix from the commit ref. Issue #24
This commit is contained in:
parent
923189eb1a
commit
b32e6172f5
@ -116,7 +116,7 @@ func (p Plugin) Exec() error {
|
||||
Client: client,
|
||||
Owner: p.Repo.Owner,
|
||||
Repo: p.Repo.Name,
|
||||
Tag: filepath.Base(p.Commit.Ref),
|
||||
Tag: strings.TrimPrefix(p.Commit.Ref, "refs/tags/"),
|
||||
Draft: p.Config.Draft,
|
||||
Prerelease: p.Config.Prerelease,
|
||||
FileExists: p.Config.FileExists,
|
||||
|
Loading…
Reference in New Issue
Block a user