mirror of
https://github.com/hrfee/jfa-go.git
synced 2024-12-22 09:00:10 +00:00
fix IsNew() func, include LICENSE in goreleaser
This commit is contained in:
parent
f685582e1a
commit
21490faa9e
@ -17,6 +17,7 @@ before:
|
|||||||
- cp node_modules/remixicon/fonts/remixicon.css node_modules/remixicon/fonts/remixicon.woff2 data/web/css/
|
- cp node_modules/remixicon/fonts/remixicon.css node_modules/remixicon/fonts/remixicon.woff2 data/web/css/
|
||||||
- cp -r html data/
|
- cp -r html data/
|
||||||
- cp -r lang data/
|
- cp -r lang data/
|
||||||
|
- cp LICENSE data/
|
||||||
- python3 scripts/enumerate_config.py -i config/config-base.json -o data/config-base.json
|
- python3 scripts/enumerate_config.py -i config/config-base.json -o data/config-base.json
|
||||||
- python3 scripts/generate_ini.py -i config/config-base.json -o data/config-default.ini
|
- python3 scripts/generate_ini.py -i config/config-base.json -o data/config-default.ini
|
||||||
- python3 scripts/compile_mjml.py -o data/
|
- python3 scripts/compile_mjml.py -o data/
|
||||||
|
@ -124,7 +124,6 @@ type Updater struct {
|
|||||||
|
|
||||||
func newUpdater(buildroneURL, namespace, repo, version, commit, buildType string) *Updater {
|
func newUpdater(buildroneURL, namespace, repo, version, commit, buildType string) *Updater {
|
||||||
bType := off
|
bType := off
|
||||||
fmt.Println("BT", buildType)
|
|
||||||
tag := ""
|
tag := ""
|
||||||
switch buildType {
|
switch buildType {
|
||||||
case "binary":
|
case "binary":
|
||||||
@ -202,7 +201,7 @@ func (ud *Updater) GetTag() (Tag, int, error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (t *Tag) IsNew() bool {
|
func (t *Tag) IsNew() bool {
|
||||||
return t.Version == version
|
return t.Version != version
|
||||||
}
|
}
|
||||||
|
|
||||||
func (ud *Updater) getRelease() (release GHRelease, status int, err error) {
|
func (ud *Updater) getRelease() (release GHRelease, status int, err error) {
|
||||||
|
1
views.go
1
views.go
@ -72,6 +72,7 @@ func (app *appContext) AdminPage(gc *gin.Context) {
|
|||||||
var license string
|
var license string
|
||||||
l, err := fs.ReadFile(localFS, "LICENSE")
|
l, err := fs.ReadFile(localFS, "LICENSE")
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
app.debug.Printf("Failed to load LICENSE: %s", err)
|
||||||
license = ""
|
license = ""
|
||||||
}
|
}
|
||||||
license = string(l)
|
license = string(l)
|
||||||
|
Loading…
Reference in New Issue
Block a user