22 Commits

Author SHA1 Message Date
s1d3sw1ped 35d888ec62 Merge pull request 'merge master into develop' (#22) from master into develop
CI / Lint (push) Successful in 1m10s
CI / Test (push) Successful in 3m38s
CI / Build (push) Successful in 4m9s
Reviewed-on: #22
2024-03-12 05:16:43 +00:00
s1d3sw1ped 15e317b6fe Merge pull request 'fix' (#21) from fix3 into master
CI / Lint (push) Successful in 50s
CI / Test (push) Successful in 3m32s
CI / Build (push) Successful in 4m4s
CI / Lint (pull_request) Successful in 1m2s
CI / Test (pull_request) Successful in 3m46s
CI / Build (pull_request) Successful in 4m18s
Reviewed-on: #21
2024-03-12 05:03:56 +00:00
s1d3sw1ped 07f11c7d22 fix
CI / Build (pull_request) Has been cancelled
CI / Test (pull_request) Has been cancelled
CI / Lint (pull_request) Has been cancelled
2024-03-12 00:03:21 -05:00
s1d3sw1ped 7c28081b65 Merge pull request 'fix' (#20) from fix2 into master
CI / Lint (push) Successful in 40s
CI / Build (push) Successful in 3m22s
CI / Test (push) Successful in 3m42s
Reviewed-on: #20
2024-03-12 04:56:40 +00:00
s1d3sw1ped d9a75a5e21 fix
CI / Test (pull_request) Has been cancelled
CI / Lint (pull_request) Has been cancelled
CI / Build (pull_request) Has been cancelled
2024-03-11 23:56:22 -05:00
s1d3sw1ped 5da6636dd7 Merge pull request 'blah' (#19) from fix into master
CI / Lint (push) Successful in 55s
CI / Test (push) Successful in 3m45s
CI / Build (push) Successful in 4m16s
Reviewed-on: #19
2024-03-12 04:40:10 +00:00
s1d3sw1ped b04e653350 blah
CI / Test (pull_request) Has been cancelled
CI / Build (pull_request) Has been cancelled
CI / Lint (pull_request) Has been cancelled
2024-03-11 23:39:24 -05:00
s1d3sw1ped 8469610328 Merge pull request 'ci and general changes' (#18) from ci_and_edits into master
CI / Lint (push) Successful in 46s
CI / Build (push) Successful in 3m36s
CI / Test (push) Successful in 4m7s
Reviewed-on: #18
2024-03-12 04:06:14 +00:00
s1d3sw1ped 9703682b4a try fixing ci again
CI / Lint (pull_request) Successful in 54s
CI / Build (pull_request) Successful in 3m35s
CI / Test (pull_request) Successful in 4m0s
2024-03-11 21:59:14 -05:00
s1d3sw1ped e281fbafdb ci and general changes
CI / Lint (pull_request) Successful in 50s
CI / Build (pull_request) Successful in 3m46s
CI / Test (pull_request) Successful in 4m6s
2024-03-11 21:42:16 -05:00
s1d3sw1ped be35430727 please
CI / Test (push) Has been cancelled
CI / Lint (push) Has been cancelled
CI / Build (push) Successful in 3m2s
2024-03-11 14:09:01 -05:00
s1d3sw1ped 3667bfae52 please
CI / Test (push) Has been cancelled
CI / Lint (push) Has been cancelled
CI / Build (push) Successful in 3m12s
2024-03-11 14:01:07 -05:00
s1d3sw1ped 8ec9119bc1 please
CI / Lint (push) Successful in 56s
CI / Test (push) Successful in 3m43s
CI / Build (push) Successful in 4m20s
2024-03-11 12:46:27 -05:00
s1d3sw1ped 4924466a93 please
CI / Lint (push) Successful in 53s
CI / Test (push) Successful in 3m5s
CI / Build (push) Failing after 1m56s
2024-03-11 11:45:17 -05:00
s1d3sw1ped e37e629630 please
CI / Lint (push) Successful in 49s
CI / Build (push) Failing after 3m2s
CI / Test (push) Successful in 3m32s
2024-03-10 22:08:51 -05:00
s1d3sw1ped e1db654a48 please
CI / Test (push) Has been cancelled
CI / Lint (push) Has been cancelled
CI / Build (push) Successful in 2m56s
2024-03-10 22:00:02 -05:00
s1d3sw1ped ee19aadac9 please
CI / Test (push) Has been cancelled
CI / Lint (push) Has been cancelled
CI / Build (push) Failing after 1m58s
2024-03-10 21:56:40 -05:00
s1d3sw1ped 17b0d9f72e please
CI / Test (push) Has been cancelled
CI / Lint (push) Has been cancelled
CI / Build (push) Successful in 3m2s
2024-03-10 21:46:47 -05:00
s1d3sw1ped 99a59b47c2 please
CI / Lint (push) Successful in 48s
CI / Build (push) Failing after 2m48s
CI / Test (push) Successful in 3m18s
2024-03-10 21:41:26 -05:00
s1d3sw1ped 77f83b89f6 Merge branch 'master' of ssh://git.s1d3sw1ped.com:2222/s1d3sw1ped/SwipedModSwitcher
CI / Lint (push) Successful in 56s
CI / Build (push) Successful in 3m12s
CI / Test (push) Successful in 3m37s
2024-03-10 21:23:53 -05:00
s1d3sw1ped 86d4095444 Merge pull request 'cleanup' (#17) from develop into master
CI / Lint (push) Successful in 48s
CI / Build (push) Successful in 3m0s
CI / Test (push) Successful in 3m20s
Reviewed-on: #17
2024-03-11 02:04:57 +00:00
s1d3sw1ped 58bb19b43f add actions 2024-03-10 00:41:03 -06:00
5 changed files with 28 additions and 20 deletions
+5 -3
View File
@@ -90,8 +90,9 @@ jobs:
- name: Build for linux
run: |
fyne package --appBuild=${BUILD} --exe bin/swiped-mod-switcher-${VERSION}.${BUILD}-${GOOS}-${GOARCH}${EXE} main.go
fyne build --os=${GOOS} --metadata Build=${BUILD} -o bin/swiped-mod-switcher-${VERSION#v}.${BUILD}-${GOOS}-${GOARCH}
env:
VERSION: ${{github.ref_name}}
BUILD: ${{github.run_number}}
GOOS: linux
GOARCH: amd64
@@ -101,12 +102,13 @@ jobs:
- name: Build for windows
run: |
fyne package --appBuild=${BUILD} --exe bin/swiped-mod-switcher-${VERSION}.${BUILD}-${GOOS}-${GOARCH}${EXE} main.go
fyne build --os=${GOOS} --metadata Build=${BUILD} -o bin/swiped-mod-switcher-${VERSION#v}.${BUILD}-${GOOS}-${GOARCH}.exe
env:
VERSION: ${{github.ref_name}}
BUILD: ${{github.run_number}}
GOOS: windows
GOARCH: amd64
EXE: .exe
EXE: ".exe"
CGO_ENABLED: 1
CC: x86_64-w64-mingw32-gcc
+4 -4
View File
@@ -91,25 +91,25 @@ jobs:
- name: Build for linux
run: |
fyne package --os ${{GOOS}} --release --appVersion=${VERSION#v} --appBuild=${BUILD} --exe bin/sw1ped-mod-switcher-${VERSION#v}.${BUILD}-linux-amd64 main.go
fyne build --os=${GOOS} --metadata Build=${BUILD} -o bin/swiped-mod-switcher-${VERSION#v}.${BUILD}-${GOOS}-${GOARCH}
ls bin
env:
VERSION: ${{github.ref_name}}
BUILD: ${{github.run_number}}
GOOS: linux
GOARCH: amd64
EXE: ""
CGO_ENABLED: 1
CC: gcc
- name: Build for windows
run: |
fyne package --os ${{GOOS}} --release --appVersion=${VERSION#v} --appBuild=${BUILD} --exe bin/sw1ped-mod-switcher-${VERSION#v}.${BUILD}-windows-amd64.exe main.go
fyne build --os=${GOOS} --metadata Build=${BUILD} -o bin/swiped-mod-switcher-${VERSION#v}.${BUILD}-${GOOS}-${GOARCH}.exe
ls bin
env:
VERSION: ${{github.ref_name}}
BUILD: ${{github.run_number}}
GOOS: windows
GOARCH: amd64
EXE: .exe
CGO_ENABLED: 1
CC: x86_64-w64-mingw32-gcc
+2 -4
View File
@@ -87,7 +87,7 @@ jobs:
- name: Build for linux
run: |
fyne package --os ${{GOOS}} --release --appVersion=${VERSION#v} --appBuild=${BUILD} --exe bin/sw1ped-mod-switcher-${VERSION#v}.${BUILD}-linux-amd64 main.go
fyne build --os=${GOOS} --metadata Build=${BUILD} -o bin/swiped-mod-switcher-${VERSION#v}.${BUILD}-${GOOS}-${GOARCH}
env:
VERSION: ${{github.ref_name}}
BUILD: ${{github.run_number}}
@@ -97,10 +97,9 @@ jobs:
CGO_ENABLED: 1
CC: gcc
- name: Build for windows
run: |
fyne package --os ${{GOOS}} --release --appVersion=${VERSION#v} --appBuild=${BUILD} --exe bin/sw1ped-mod-switcher-${VERSION#v}.${BUILD}-windows-amd64.exe main.go
fyne build --os=${GOOS} --metadata Build=${BUILD} -o bin/swiped-mod-switcher-${VERSION#v}.${BUILD}-${GOOS}-${GOARCH}.exe
env:
VERSION: ${{github.ref_name}}
BUILD: ${{github.run_number}}
@@ -110,7 +109,6 @@ jobs:
CGO_ENABLED: 1
CC: x86_64-w64-mingw32-gcc
- name: Release binaries
uses: https://gitea.com/actions/release-action@main
with:
+1 -1
View File
@@ -3,4 +3,4 @@ Icon = "icon.png"
Name = "Swiped Mod Switcher"
ID = "com.s1d3sw1ped.swipedmodswitcher"
Version = "0.0.0"
Build = 1
Build = 2
+8
View File
@@ -18,6 +18,8 @@ import (
"gopkg.in/yaml.v3"
)
var Version = ""
type Config struct {
ModProfilesDirectory string `yaml:"mod_profiles_dir"`
GameModsDirectory string `yaml:"game_mods_dir"`
@@ -61,10 +63,12 @@ var cfg *Config
func main() {
if !admin.Admin() {
fmt.Println("not running as administrator relaunching")
if err := admin.RunSelfElevated(); err != nil {
panic(err)
}
os.Exit(0)
return // just incase
}
cfg = loadConfig()
@@ -136,10 +140,14 @@ func fillGrid(grid *fyne.Container, parent fyne.Window) {
grid.Hide()
defer grid.Show()
grid.RemoveAll()
if admin.Admin() {
for _, profile := range profiles {
profilename := filepath.Base(profile)
grid.Add(widget.NewButton(profilename, makeIFunc(profile, archive, parent)))
}
} else {
grid.Add(widget.NewLabel("not running as administrator"))
}
}
func scanProfiles(profilesroot string) []string {