Skip to content

Commit

Permalink
update deps; update aux files; restructure
Browse files Browse the repository at this point in the history
  • Loading branch information
aine-etke committed Dec 12, 2024
1 parent c3a6668 commit b9e80e9
Show file tree
Hide file tree
Showing 14 changed files with 166 additions and 27 deletions.
8 changes: 1 addition & 7 deletions .github/workflows/workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,7 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
- name: add just repo
run: |
wget -qO - 'https://proget.makedeb.org/debian-feeds/prebuilt-mpr.pub' | gpg --dearmor | sudo tee /usr/share/keyrings/prebuilt-mpr-archive-keyring.gpg 1> /dev/null
echo "deb [arch=all,$(dpkg --print-architecture) signed-by=/usr/share/keyrings/prebuilt-mpr-archive-keyring.gpg] https://proget.makedeb.org prebuilt-mpr $(lsb_release -cs)" | sudo tee /etc/apt/sources.list.d/prebuilt-mpr.list
- uses: ConorMacBride/install-package@v1
with:
apt: just
- uses: extractions/setup-just@v1
- name: lint
uses: golangci/golangci-lint-action@v6
with:
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
/cover.out
/.env
2 changes: 1 addition & 1 deletion .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ linters:
- bidichk
- bodyclose
- containedctx
- copyloopvar
- decorder
- dogsled
- dupl
Expand All @@ -86,7 +87,6 @@ linters:
- errname
- errorlint
- exhaustive
- exportloopref
- forcetypeassert
- gocognit
- gocritic
Expand Down
2 changes: 1 addition & 1 deletion .goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ builds:
- -extldflags "-static"
flags:
- -tags=timetzdata,goolm
main: ./cmd/
main: ./cmd/ttm
goos:
- linux
- windows
Expand Down
File renamed without changes.
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
module github.com/etkecc/ttm

go 1.17
go 1.22

require (
github.com/creack/pty v1.1.21
github.com/creack/pty v1.1.24
github.com/etkecc/go-env v1.2.1
)
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
github.com/creack/pty v1.1.21 h1:1/QdRyBaHHJP61QkWMXlOIBfsgdDeeKfK8SYVUWJKf0=
github.com/creack/pty v1.1.21/go.mod h1:MOBLtS5ELjhRRrroQr9kyvTxUAFNvYEK993ew/Vr4O4=
github.com/creack/pty v1.1.24 h1:bJrF4RRfyJnbTJqzRLHzcGaZK1NeM5kTC9jGgovnR1s=
github.com/creack/pty v1.1.24/go.mod h1:08sCNb52WyoAwi2QDyzUCTgcvVFhUzewun7wtTfvcwE=
github.com/etkecc/go-env v1.2.1 h1:b/mIa8D1d9hc3rI8h5bEtBHsnKkBZ6UbmYPog3QIPTU=
github.com/etkecc/go-env v1.2.1/go.mod h1:yTs1DWEsllAZYA417r4V+OmMuYinGXtBzKkLGNvCv5c=
6 changes: 3 additions & 3 deletions internal/matrix/matrix_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package matrix
import (
"bytes"
"context"
"io/ioutil"
"io"
"net/http"
"net/http/httptest"
"reflect"
Expand Down Expand Up @@ -154,7 +154,7 @@ func TestSendMessage(t *testing.T) {
if actualPath != expectedPath {
t.Error("request url is not expected. actual:", actualPath)
}
requestBody, err := ioutil.ReadAll(r.Body)
requestBody, err := io.ReadAll(r.Body)
if err != nil {
t.Error("sent request body cannot be read")
}
Expand Down Expand Up @@ -189,7 +189,7 @@ func startServer(t *testing.T, expectedPath string, expectedRequestBody, respons
if actualPath != expectedPath {
t.Error("request url is not expected. actual:", actualPath)
}
requestBody, err := ioutil.ReadAll(r.Body)
requestBody, err := io.ReadAll(r.Body)
if err != nil {
t.Error("sent request body cannot be read")
}
Expand Down
12 changes: 8 additions & 4 deletions justfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ default:

# update go deps
update *flags:
go get {{ flags }} ./cmd
go get {{ flags }} ./cmd/ttm
go mod tidy
go mod vendor

Expand All @@ -27,9 +27,13 @@ test packages="./...":
-@rm -f cover.out

# run app
run:
@go run ./cmd
run *flags:
@go run ./cmd/ttm {{ flags }}

# install app
install:
@CGO_ENABLED=0 go install -ldflags '-extldflags "-static"' -tags timetzdata,goolm -v ./cmd/ttm

# build app
build:
CGO_ENABLED=0 go build -ldflags '-extldflags "-static"' -tags timetzdata,goolm -v -o ttm ./cmd
@CGO_ENABLED=0 go build -ldflags '-extldflags "-static"' -tags timetzdata,goolm -v ./cmd/ttm
2 changes: 1 addition & 1 deletion vendor/github.com/creack/pty/README.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions vendor/github.com/creack/pty/pty_unsupported.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

141 changes: 141 additions & 0 deletions vendor/github.com/creack/pty/pty_zos.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions vendor/github.com/creack/pty/ztypes_openbsd_32bit_int.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions vendor/modules.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# github.com/creack/pty v1.1.21
## explicit; go 1.13
# github.com/creack/pty v1.1.24
## explicit; go 1.18
github.com/creack/pty
# github.com/etkecc/go-env v1.2.1
## explicit; go 1.18
Expand Down

0 comments on commit b9e80e9

Please sign in to comment.