tangled
alpha
login
or
join now
stream.place
/
streamplace
74
fork
atom
Live video on the AT Protocol
74
fork
atom
overview
issues
1
pulls
pipelines
this works?
Natalie B.
2 months ago
d452a116
ebe5c032
+15
-1
1 changed file
expand all
collapse all
unified
split
pkg
config
git
git.go
+15
-1
pkg/config/git/git.go
···
84
84
flag.Parse()
85
85
r, err := git.PlainOpenWithOptions(".", &git.PlainOpenOptions{DetectDotGit: true})
86
86
if err != nil {
87
87
-
return err
87
87
+
// fallback for CI environments without full git history
88
88
+
var out string
89
89
+
if *javascript {
90
90
+
out = fmt.Sprintf(tmplJS, "unknown", 0, "00000000-0000-0000-0000-000000000000")
91
91
+
} else {
92
92
+
out = fmt.Sprintf(tmpl, "unknown", 0, "00000000-0000-0000-0000-000000000000")
93
93
+
}
94
94
+
if *output != "" {
95
95
+
if err := os.WriteFile(*output, []byte(out), 0644); err != nil {
96
96
+
return err
97
97
+
}
98
98
+
} else {
99
99
+
fmt.Print(out)
100
100
+
}
101
101
+
return nil
88
102
}
89
103
90
104
// ... retrieving the HEAD reference