chore: rename artifacts

This commit is contained in:
DaanSelen
2026-03-30 13:37:18 +02:00
parent 1ae2620e7e
commit d5844bf28a
2 changed files with 27 additions and 9 deletions
+4 -4
View File
@@ -53,7 +53,7 @@ jobs:
- name: Upload binaries as artifacts
uses: actions/upload-artifact@v3
with:
name: linux-bin
name: bin-linux
path: /dist
prepare-windows:
@@ -120,7 +120,7 @@ jobs:
- name: Upload binaries as artifacts
uses: actions/upload-artifact@v3
with:
name: windows-bin
name: bin-windows
path: /dist
compile-linux:
@@ -135,7 +135,7 @@ jobs:
- name: Download artifacts
uses: actions/download-artifact@v3
with:
name: linux-bin
name: bin-linux
path: ./bin
- name: Setup the Go programming language
@@ -188,7 +188,7 @@ jobs:
- name: Download artifacts
uses: actions/download-artifact@v3
with:
name: windows-bin
name: bin-windows
path: ./bin
- name: Setup the Go programming language
+21 -3
View File
@@ -1,15 +1,33 @@
package setup
import "os"
import (
"log"
"os"
)
func PrepareEnvironment() (bool, error) {
if _, err := os.Stat("./bin"); err != nil {
ok, err := fsCheck()
return ok, err
}
func fsCheck() (bool, error) {
dirs := []string{"./bin", "./books", "./history"}
files := []string{"./api.conf", "./os_categories.json"}
for _, d := range dirs {
if _, err := os.Stat(d); err != nil {
log.Printf("Unable to stat dir: %s", d)
return false, err
}
}
if _, err := os.Stat("./books"); err != nil {
for _, f := range files {
if _, err := os.Stat(f); err != nil {
log.Printf("Unable to stat file: %s", f)
return false, err
}
}
return true, nil
}