Skip to content
Snippets Groups Projects
Verified Commit 5ba9c8e9 authored by Volker Schukai's avatar Volker Schukai :alien:
Browse files

fix: versioning

parent 3560b1f7
Branches
Tags 0.5.5
No related merge requests found
......@@ -7,6 +7,7 @@
outputs = {
self,
nixpkgs,
...
}: let
# to work with older version of flakes
lastModifiedDate = self.lastModifiedDate or self.lastModified or "19700101";
......@@ -47,8 +48,8 @@
ldflags = [
"-X 'gitlab.schukai.com/oss/bob/release.version=${goPkgVersion}'"
"-X 'gitlab.schukai.com/oss/bob/release.commit=${goPkgHash}'"
"-X 'gitlab.schukai.com/oss/bob/release.buildDate=${lastModifiedDate}'"
"-X 'gitlab.schukai.com/oss/bob/release.commit=${self.rev or "unknown"}'"
"-X 'gitlab.schukai.com/oss/bob/release.buildDate=${self.lastModifiedDate or "unknown"}'"
"-X 'gitlab.schukai.com/oss/bob/release.name=${goPkgName}'"
"-X 'gitlab.schukai.com/oss/bob/release.mnemonic=${goPkgMnemonic}'"
];
......
......@@ -5,7 +5,5 @@
supportedSystems = ["x86_64-linux" "x86_64-darwin" "aarch64-linux" "aarch64-darwin"];
compileForSystems = ["linux/arm64" "linux/amd64" "darwin/amd64" "windows/amd64"];
modulePath = "gitlab.schukai.com/oss/bob";
version = "0.5.0"; ## do not change this line; it will be updated automatically
vendorHash = null; ## do not change this line; it will be updated automatically
commitHash = "0747ca6"; ## do not change this line; it will be updated automatically
version = "0.5.5"; ## do not change this line; it will be updated automatically
}
......@@ -9,6 +9,7 @@ import (
"gopkg.in/yaml.v3"
"os"
"path/filepath"
"strings"
)
type Specification struct {
......@@ -255,10 +256,25 @@ func checkExcludes(exclude []string, d string) (bool, error) {
return false, err
}
if e == "" {
continue
}
if e == d {
return true, nil
}
fileInfo, err := os.Stat(e)
if err != nil {
return false, err
}
if fileInfo.IsDir() {
if strings.HasPrefix(d, e) {
return true, nil
}
}
if r, err := filepath.Match(e, d); err != nil {
return false, err
} else if r {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment