Skip to content

Commit

Permalink
Update workflows
Browse files Browse the repository at this point in the history
Signed-off-by: Fxzx micah <[email protected]>
  • Loading branch information
fxzxmicah committed Jan 30, 2023
1 parent 48ecb0a commit 7434920
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 18 deletions.
10 changes: 3 additions & 7 deletions .github/workflows/linter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,11 @@ jobs:
steps:
- uses: actions/checkout@v3

- name: Get latest go version
id: version
run: |
echo "::set-output name=value::$(curl 'https://raw.githubusercontent.com/actions/go-versions/main/versions-manifest.json' --silent | jq '.[0].version' -r)"
- name: Setup Go
uses: actions/setup-go@v2
uses: actions/setup-go@v3
with:
go-version: ${{ steps.version.outputs.value }}
check-latest: true
go-version: '1.19'

- name: golangci-lint
uses: golangci/golangci-lint-action@v3
Expand Down
10 changes: 3 additions & 7 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,11 @@ jobs:
build:
runs-on: windows-latest
steps:
- name: Get latest go version
id: version
run: |
echo "::set-output name=value::$(curl 'https://raw.githubusercontent.com/actions/go-versions/main/versions-manifest.json' --silent | jq '.[0].version' -r)"
- name: Setup Go
uses: actions/setup-go@v2
uses: actions/setup-go@v3
with:
go-version: ${{ steps.version.outputs.value }}
check-latest: true
go-version: '1.19'

- name: Check out code
uses: actions/checkout@v3
Expand Down
8 changes: 4 additions & 4 deletions dns/resolver.go
Original file line number Diff line number Diff line change
Expand Up @@ -345,10 +345,10 @@ func NewResolver(config Config) *Resolver {
}

r := &Resolver{
ipv6: config.IPv6,
main: transform(config.Main, defaultResolver),
lruCache: cache.New(cache.WithSize(4096), cache.WithStale(true)),
hosts: config.Hosts,
ipv6: config.IPv6,
main: transform(config.Main, defaultResolver),
lruCache: cache.New(cache.WithSize(4096), cache.WithStale(true)),
hosts: config.Hosts,
}

if len(config.Fallback) != 0 {
Expand Down

0 comments on commit 7434920

Please sign in to comment.