Skip to content

Commit

Permalink
fix: error in checkoutt diff
Browse files Browse the repository at this point in the history
Fixes an error with checking out repository.
Also rekres and bump deps.

Signed-off-by: Noel Georgi <[email protected]>
  • Loading branch information
frezbo committed Mar 1, 2024
1 parent 43d9fb6 commit a6572d2
Show file tree
Hide file tree
Showing 8 changed files with 58 additions and 47 deletions.
77 changes: 44 additions & 33 deletions .conform.yaml
Original file line number Diff line number Diff line change
@@ -1,37 +1,48 @@
# THIS FILE WAS AUTOMATICALLY GENERATED, PLEASE DO NOT EDIT.
#
# Generated on 2022-09-19T19:55:11Z by kres 255fc05.
# Generated on 2024-03-01T05:36:30Z by kres latest.

---
policies:
- type: commit
spec:
dco: true
gpg:
required: true
identity:
gitHubOrganization: siderolabs
spellcheck:
locale: US
maximumOfOneCommit: true
header:
length: 89
imperative: true
case: lower
invalidLastCharacters: .
body:
required: true
conventional:
types: ["chore","docs","perf","refactor","style","test","release"]
scopes: [".*"]
- type: license
spec:
skipPaths:
- .git/
- testdata/
includeSuffixes:
- .go
excludeSuffixes:
- .pb.go
- .pb.gw.go
header: "// This Source Code Form is subject to the terms of the Mozilla Public\u000A// License, v. 2.0. If a copy of the MPL was not distributed with this\u000A// file, You can obtain one at http://mozilla.org/MPL/2.0/.\u000A"
- type: commit
spec:
dco: true
gpg:
required: true
identity:
gitHubOrganization: siderolabs
spellcheck:
locale: US
maximumOfOneCommit: true
header:
length: 89
imperative: true
case: lower
invalidLastCharacters: .
body:
required: true
conventional:
types:
- chore
- docs
- perf
- refactor
- style
- test
- release
scopes:
- .*
- type: license
spec:
root: .
skipPaths:
- .git/
- testdata/
includeSuffixes:
- .go
excludeSuffixes:
- .pb.go
- .pb.gw.go
header: |
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

# THIS FILE WAS AUTOMATICALLY GENERATED, PLEASE DO NOT EDIT.
#
# Generated on 2024-02-15T11:12:36Z by kres latest.
# Generated on 2024-03-01T05:36:30Z by kres latest.

ARG TOOLCHAIN

Expand All @@ -11,7 +11,7 @@ FROM ghcr.io/siderolabs/ca-certificates:v1.6.0 AS image-ca-certificates
FROM ghcr.io/siderolabs/fhs:v1.6.0 AS image-fhs

# runs markdownlint
FROM docker.io/node:21.6.1-alpine3.19 AS lint-markdown
FROM docker.io/node:21.6.2-alpine3.19 AS lint-markdown
WORKDIR /src
RUN npm i -g [email protected]
RUN npm i [email protected]
Expand Down
8 changes: 4 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# THIS FILE WAS AUTOMATICALLY GENERATED, PLEASE DO NOT EDIT.
#
# Generated on 2024-02-15T11:12:36Z by kres latest.
# Generated on 2024-03-01T05:36:30Z by kres latest.

# common variables

Expand All @@ -18,11 +18,11 @@ PROTOBUF_GO_VERSION ?= 1.32.0
GRPC_GO_VERSION ?= 1.3.0
GRPC_GATEWAY_VERSION ?= 2.19.1
VTPROTOBUF_VERSION ?= 0.6.0
DEEPCOPY_VERSION ?= v0.5.5
GOLANGCILINT_VERSION ?= v1.56.1
DEEPCOPY_VERSION ?= v0.5.6
GOLANGCILINT_VERSION ?= v1.56.2
GOFUMPT_VERSION ?= v0.6.0
GO_VERSION ?= 1.22.0
GOIMPORTS_VERSION ?= v0.17.0
GOIMPORTS_VERSION ?= v0.18.0
GO_BUILDFLAGS ?=
GO_LDFLAGS ?=
CGO_ENABLED ?= 0
Expand Down
6 changes: 3 additions & 3 deletions cmd/conform/serve.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import (
git "github.com/go-git/go-git/v5"
"github.com/go-git/go-git/v5/config"
"github.com/go-git/go-git/v5/plumbing"
"github.com/google/go-github/v59/github"
"github.com/google/go-github/v60/github"
"github.com/spf13/cobra"
)

Expand Down Expand Up @@ -91,7 +91,7 @@ var serveCmd = &cobra.Command{

id := pullRequestEvent.GetPullRequest().GetNumber()

ref := plumbing.ReferenceName(pullRequestEvent.GetPullRequest().GetHead().GetRef())
ref := pullRequestEvent.GetPullRequest().GetHead().GetRef()

refSpec := fmt.Sprintf("refs/pull/%d/head:%s", id, ref)

Expand All @@ -116,7 +116,7 @@ var serveCmd = &cobra.Command{
}

err = worktree.Checkout(&git.CheckoutOptions{
Branch: ref,
Branch: plumbing.NewBranchReferenceName(ref),
})
if err != nil {
log.Printf("failed to checkout %q: %v", ref, err)
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ require (
github.com/denormal/go-gitignore v0.0.0-20180930084346-ae8ad1d07817
github.com/go-git/go-git/v5 v5.11.0
github.com/golangci/misspell v0.4.1
github.com/google/go-github/v59 v59.0.0
github.com/google/go-github/v60 v60.0.0
github.com/jdkato/prose/v3 v3.0.0-20210921205322-a376476c2627
github.com/keybase/go-crypto v0.0.0-20200123153347-de78d2cb44f4
github.com/mitchellh/mapstructure v1.5.0
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ github.com/golangci/misspell v0.4.1/go.mod h1:9mAN1quEo3DlpbaIKKyEvRxK1pwqR9s/Se
github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE=
github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI=
github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY=
github.com/google/go-github/v59 v59.0.0 h1:7h6bgpF5as0YQLLkEiVqpgtJqjimMYhBkD4jT5aN3VA=
github.com/google/go-github/v59 v59.0.0/go.mod h1:rJU4R0rQHFVFDOkqGWxfLNo6vEk4dv40oDjhV/gH6wM=
github.com/google/go-github/v60 v60.0.0 h1:oLG98PsLauFvvu4D/YPxq374jhSxFYdzQGNCyONLfn8=
github.com/google/go-github/v60 v60.0.0/go.mod h1:ByhX2dP9XT9o/ll2yXAu2VD8l5eNVg8hD4Cr0S/LmQk=
github.com/google/go-querystring v1.1.0 h1:AnCroh3fv4ZBgVIf1Iwtovgjaw/GiKJo8M8yD/fhyJ8=
github.com/google/go-querystring v1.1.0/go.mod h1:Kcdr2DB4koayq7X8pmAG4sNG59So17icRSOU623lUBU=
github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8=
Expand Down
2 changes: 1 addition & 1 deletion internal/policy/commit/check_gpg_identity.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import (
"net/http"
"sync"

"github.com/google/go-github/v59/github"
"github.com/google/go-github/v60/github"
"golang.org/x/sync/errgroup"

"github.com/siderolabs/conform/internal/git"
Expand Down
2 changes: 1 addition & 1 deletion internal/reporter/reporter.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import (
"path"
"strings"

"github.com/google/go-github/v59/github"
"github.com/google/go-github/v60/github"
)

// Reporter describes a hook for sending summarized results to a remote API.
Expand Down

0 comments on commit a6572d2

Please sign in to comment.