mirror of
https://github.com/mikefarah/yq.git
synced 2026-07-10 00:05:38 +00:00
Compare commits
6 Commits
3adc17be9f
...
34ce547a80
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
34ce547a80 | ||
|
|
4df6e46f95 | ||
|
|
6a965bc39a | ||
|
|
34d3a29308 | ||
|
|
16e4df2304 | ||
|
|
9883ebc313 |
6
.github/workflows/docker-release.yml
vendored
6
.github/workflows/docker-release.yml
vendored
@ -23,7 +23,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Set up Docker Buildx
|
- name: Set up Docker Buildx
|
||||||
id: buildx
|
id: buildx
|
||||||
uses: docker/setup-buildx-action@v3
|
uses: docker/setup-buildx-action@v4
|
||||||
with:
|
with:
|
||||||
version: latest
|
version: latest
|
||||||
|
|
||||||
@ -31,13 +31,13 @@ jobs:
|
|||||||
run: echo ${{ steps.buildx.outputs.platforms }} && docker version
|
run: echo ${{ steps.buildx.outputs.platforms }} && docker version
|
||||||
|
|
||||||
- name: Login to Docker Hub
|
- name: Login to Docker Hub
|
||||||
uses: docker/login-action@v3
|
uses: docker/login-action@v4
|
||||||
with:
|
with:
|
||||||
username: ${{ secrets.DOCKER_USERNAME }}
|
username: ${{ secrets.DOCKER_USERNAME }}
|
||||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||||
|
|
||||||
- name: Login to GitHub Container Registry
|
- name: Login to GitHub Container Registry
|
||||||
uses: docker/login-action@v3
|
uses: docker/login-action@v4
|
||||||
with:
|
with:
|
||||||
registry: ghcr.io
|
registry: ghcr.io
|
||||||
username: ${{ github.actor }}
|
username: ${{ github.actor }}
|
||||||
|
|||||||
2
.github/workflows/release.yml
vendored
2
.github/workflows/release.yml
vendored
@ -44,7 +44,7 @@ jobs:
|
|||||||
./scripts/xcompile.sh
|
./scripts/xcompile.sh
|
||||||
|
|
||||||
- name: Release
|
- name: Release
|
||||||
uses: softprops/action-gh-release@v1
|
uses: softprops/action-gh-release@v2
|
||||||
with:
|
with:
|
||||||
files: build/*
|
files: build/*
|
||||||
draft: true
|
draft: true
|
||||||
|
|||||||
@ -1,4 +1,4 @@
|
|||||||
FROM golang:1.26.0 AS builder
|
FROM golang:1.26.1 AS builder
|
||||||
|
|
||||||
WORKDIR /go/src/mikefarah/yq
|
WORKDIR /go/src/mikefarah/yq
|
||||||
|
|
||||||
|
|||||||
@ -1,4 +1,4 @@
|
|||||||
FROM golang:1.26.0
|
FROM golang:1.26.1
|
||||||
|
|
||||||
RUN apt-get update && \
|
RUN apt-get update && \
|
||||||
apt-get install -y npm && \
|
apt-get install -y npm && \
|
||||||
|
|||||||
@ -911,7 +911,7 @@ func stringsEqual(a, b []string) bool {
|
|||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
for i := range a {
|
for i := range a {
|
||||||
if a[i] != b[i] {
|
if a[i] != b[i] { //nolint:gosec // G602 false positive: b length equality is checked above
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -280,7 +280,7 @@ func (n *CandidateNode) AddChild(rawChild *CandidateNode) {
|
|||||||
|
|
||||||
func (n *CandidateNode) AddChildren(children []*CandidateNode) {
|
func (n *CandidateNode) AddChildren(children []*CandidateNode) {
|
||||||
if n.Kind == MappingNode {
|
if n.Kind == MappingNode {
|
||||||
for i := 0; i < len(children); i += 2 {
|
for i := 0; i < len(children)-1; i += 2 {
|
||||||
key := children[i]
|
key := children[i]
|
||||||
value := children[i+1]
|
value := children[i+1]
|
||||||
n.AddKeyValueChild(key, value)
|
n.AddKeyValueChild(key, value)
|
||||||
|
|||||||
@ -29,7 +29,7 @@ func GetLogger() *logging.Logger {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func getContentValueByKey(content []*CandidateNode, key string) *CandidateNode {
|
func getContentValueByKey(content []*CandidateNode, key string) *CandidateNode {
|
||||||
for index := 0; index < len(content); index = index + 2 {
|
for index := 0; index < len(content)-1; index = index + 2 {
|
||||||
keyNode := content[index]
|
keyNode := content[index]
|
||||||
valueNode := content[index+1]
|
valueNode := content[index+1]
|
||||||
if keyNode.Value == key {
|
if keyNode.Value == key {
|
||||||
|
|||||||
@ -3,8 +3,6 @@
|
|||||||
set -o errexit
|
set -o errexit
|
||||||
set -o pipefail
|
set -o pipefail
|
||||||
|
|
||||||
# TODO: Check if the found golangci-lint version matches the expected version (e.g., v1.62.0), especially if falling back to PATH version.
|
|
||||||
|
|
||||||
GOPATH_LINT="$(go env GOPATH)/bin/golangci-lint"
|
GOPATH_LINT="$(go env GOPATH)/bin/golangci-lint"
|
||||||
BIN_LINT="./bin/golangci-lint"
|
BIN_LINT="./bin/golangci-lint"
|
||||||
LINT_CMD=""
|
LINT_CMD=""
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
set -ex
|
set -ex
|
||||||
go mod download golang.org/x/tools@latest
|
go mod download golang.org/x/tools@latest
|
||||||
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v2.1.5
|
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v2.11.3
|
||||||
curl -sSfL https://raw.githubusercontent.com/securego/gosec/master/install.sh | sh -s v2.22.11
|
curl -sSfL https://raw.githubusercontent.com/securego/gosec/master/install.sh | sh -s v2.22.11
|
||||||
Loading…
Reference in New Issue
Block a user