remove ioutil call
- fix goreleaser yaml file - add goreleaser to flake shell
This commit is contained in:
parent
3f4b81fb81
commit
e54bb537f6
@ -32,17 +32,6 @@ builds:
|
||||
- darwin
|
||||
ldflags:
|
||||
- -s -w -X main.build={{.Version}}
|
||||
archives:
|
||||
- replacements:
|
||||
openbsd: OpenBSD
|
||||
freebsd: FreeBSD
|
||||
netbsd: NetBSD
|
||||
dragonfly: DragonflyBSD
|
||||
darwin: Darwin
|
||||
linux: Linux
|
||||
windows: Windows
|
||||
386: i386
|
||||
amd64: x86_64
|
||||
signs:
|
||||
- artifacts: checksum
|
||||
source:
|
||||
|
@ -42,7 +42,14 @@
|
||||
nix flake run github:qbit/xin#flake-warn
|
||||
echo "Go `${pkgs.go}/bin/go version`"
|
||||
'';
|
||||
nativeBuildInputs = with pkgs; [ git go gopls go-tools nilaway ];
|
||||
nativeBuildInputs = with pkgs; [
|
||||
git
|
||||
go
|
||||
gopls
|
||||
goreleaser
|
||||
go-tools
|
||||
nilaway
|
||||
];
|
||||
};
|
||||
});
|
||||
};
|
||||
|
3
main.go
3
main.go
@ -6,7 +6,6 @@ import (
|
||||
"encoding/csv"
|
||||
"flag"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"log"
|
||||
"net"
|
||||
"net/http"
|
||||
@ -152,7 +151,7 @@ func createEmpty(path string) error {
|
||||
if os.IsNotExist(fErr) {
|
||||
log.Printf("creating %q\n", path)
|
||||
twData, _ := tiddly.ReadFile(twFile)
|
||||
wErr := ioutil.WriteFile(path, twData, 0600)
|
||||
wErr := os.WriteFile(path, twData, 0600)
|
||||
if wErr != nil {
|
||||
return wErr
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user