[in] creates file 'tag' containing git tag for the release being fetched
This commit is contained in:
@@ -4,6 +4,7 @@ import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"io"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"os"
|
||||
"path/filepath"
|
||||
@@ -58,6 +59,12 @@ func (c *InCommand) Run(destDir string, request InRequest) (InResponse, error) {
|
||||
return InResponse{}, fmt.Errorf("could not find release with tag: %s", request.Version.Tag)
|
||||
}
|
||||
|
||||
tagPath := filepath.Join(destDir, "tag")
|
||||
err = ioutil.WriteFile(tagPath, []byte(*foundRelease.TagName), 0644)
|
||||
if err != nil {
|
||||
return InResponse{}, err
|
||||
}
|
||||
|
||||
assets, err := c.github.ListReleaseAssets(foundRelease)
|
||||
if err != nil {
|
||||
return InResponse{}, err
|
||||
|
Reference in New Issue
Block a user