mirror of
https://github.com/usememos/memos.git
synced 2025-06-05 22:09:59 +02:00
chore: clean binary entries
This commit is contained in:
@@ -3,7 +3,7 @@ tmp_dir = ".air"
|
||||
|
||||
[build]
|
||||
bin = "./.air/memos.exe --mode dev"
|
||||
cmd = "go build -o ./.air/memos.exe ./main.go"
|
||||
cmd = "go build -o ./.air/memos.exe ./bin/memos/main.go"
|
||||
delay = 1000
|
||||
exclude_dir = [".air", "web", "build"]
|
||||
include_ext = ["go", "mod", "sum"]
|
||||
|
@@ -3,7 +3,7 @@ tmp_dir = ".air"
|
||||
|
||||
[build]
|
||||
bin = "./.air/memos --mode dev"
|
||||
cmd = "go build -o ./.air/memos ./main.go"
|
||||
cmd = "go build -o ./.air/memos ./bin/memos/main.go"
|
||||
delay = 1000
|
||||
exclude_dir = [".air", "web", "build"]
|
||||
include_ext = ["go", "mod", "sum"]
|
||||
|
@@ -114,7 +114,7 @@ $backendTime = Measure-Command {
|
||||
}
|
||||
|
||||
Write-Host "Building $os/$arch to $output..." -f Blue
|
||||
&go build -trimpath -o $output -ldflags="$($ldFlags -join " ")" ./main.go | Out-Host
|
||||
&go build -trimpath -o $output -ldflags="$($ldFlags -join " ")" ./bin/memos/main.go | Out-Host
|
||||
if (!$?) {
|
||||
Write-Host -BackgroundColor red -ForegroundColor white "'go build' failed for $build ($outputBinary)!. See above."
|
||||
continue
|
||||
|
@@ -118,10 +118,10 @@ for build in "${goBuilds[@]}"; do
|
||||
output="$output.exe"
|
||||
fi
|
||||
|
||||
CGO_ENABLED=0 GOOS=$os GOARCH=$arch go build -trimpath -ldflags="${ldFlags[*]}" -o "$output" ./main.go
|
||||
CGO_ENABLED=0 GOOS=$os GOARCH=$arch go build -trimpath -ldflags="${ldFlags[*]}" -o "$output" ./bin/memos/main.go
|
||||
|
||||
echo -e "\033[34mBuilding $os/$arch to $output...\033[0m"
|
||||
GOOS=$os GOARCH=$arch go build -ldflags="${ldFlags[*]}" -o "./build/memos-$os-$arch" ./main.go
|
||||
GOOS=$os GOARCH=$arch go build -ldflags="${ldFlags[*]}" -o "./build/memos-$os-$arch" ./bin/memos/main.go
|
||||
if [ $? -ne 0 ]; then
|
||||
echo -e "\033[0;31mgo build failed for $os/$arch($output)! See above.\033[0m"
|
||||
fi
|
||||
|
Reference in New Issue
Block a user