diff options
-rw-r--r-- | .github/workflows/presubmit.yml | 2 | ||||
-rw-r--r-- | .github/workflows/scan.yml | 6 | ||||
-rw-r--r-- | .github/workflows/trunk.yml | 9 | ||||
-rw-r--r-- | CONTRIBUTING.md | 4 | ||||
-rw-r--r-- | Makefile | 13 | ||||
-rw-r--r-- | README.md | 2 | ||||
-rw-r--r-- | bridge/jira/config.go | 2 | ||||
-rw-r--r-- | cliff.toml | 26 | ||||
-rw-r--r-- | commands/commands.go | 80 | ||||
-rw-r--r-- | commands/root.go | 80 | ||||
-rw-r--r-- | commands/version.go | 87 | ||||
-rw-r--r-- | doc/generate.go | 2 | ||||
-rw-r--r-- | doc/man/git-bug-commands.1 | 26 | ||||
-rw-r--r-- | doc/man/git-bug-version.1 | 37 | ||||
-rw-r--r-- | doc/man/git-bug.1 | 2 | ||||
-rw-r--r-- | doc/md/git-bug.md | 3 | ||||
-rw-r--r-- | doc/md/git-bug_commands.md | 19 | ||||
-rw-r--r-- | doc/md/git-bug_version.md | 38 | ||||
-rw-r--r-- | entity/dag/example_test.go | 2 | ||||
-rw-r--r-- | go.mod | 44 | ||||
-rw-r--r-- | go.sum | 150 | ||||
-rw-r--r-- | main.go | 8 | ||||
-rw-r--r-- | misc/completion/generate.go | 2 | ||||
-rw-r--r-- | repository/gogit_test.go | 2 | ||||
-rw-r--r-- | repository/index_bleve.go | 29 | ||||
-rw-r--r-- | version.go | 94 |
26 files changed, 325 insertions, 444 deletions
diff --git a/.github/workflows/presubmit.yml b/.github/workflows/presubmit.yml index a6a17fa89..35bf4dc7e 100644 --- a/.github/workflows/presubmit.yml +++ b/.github/workflows/presubmit.yml @@ -14,7 +14,7 @@ on: - checks_requested pull_request: branches: - - master + - trunk concurrency: group: ${{ github.ref }} diff --git a/.github/workflows/scan.yml b/.github/workflows/scan.yml index 5279ae354..98d44d480 100644 --- a/.github/workflows/scan.yml +++ b/.github/workflows/scan.yml @@ -3,9 +3,11 @@ name: scan on: push: - branches: [master] + branches: + - trunk pull_request: - branches: [master] + branches: + - trunk schedule: - cron: '0 12 * * 6' diff --git a/.github/workflows/trunk.yml b/.github/workflows/trunk.yml index 714e94c7a..6b7bbd86a 100644 --- a/.github/workflows/trunk.yml +++ b/.github/workflows/trunk.yml @@ -9,7 +9,7 @@ name: trunk on: push: branches: - - master + - trunk concurrency: group: ${{ github.ref }} @@ -48,8 +48,7 @@ jobs: auto-push: true mirror: - if: > - github.ref == 'refs/heads/master' && github.repository == 'git-bug/git-bug' && github.run_attempt == '1' + if: github.repository == 'git-bug/git-bug' && github.run_attempt == '1' permissions: contents: write runs-on: ubuntu-latest @@ -70,11 +69,11 @@ jobs: ssh-agent -a $SSH_AUTH_SOCK > /dev/null ssh-add ~/.ssh/id_rsa - - name: push to trunk + - name: push to refs/heads/master env: SSH_AUTH_SOCK: /tmp/ssh-agent.sock run: |- git config user.name git-bug-bot git config user.email no-reply@git-bug.org git remote set-url origin git@github.com:git-bug/git-bug.git - git push --atomic origin HEAD:refs/heads/trunk + git push --atomic origin HEAD:refs/heads/master diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 5dd21f194..2665fa7e3 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -348,8 +348,8 @@ ______________________________________________________________________ [doc/design/model]: ./doc/design/data-model.md [envrc]: ./.envrc [example-entity]: ./entity/dag/example_test.go -[install/direnv]: https://github.com/direnv/direnv/blob/master/docs/installation.md -[install/direnv/shell]: https://github.com/direnv/direnv/blob/master/docs/hook.md +[install/direnv]: https://github.com/direnv/direnv/blob/trunk/docs/installation.md +[install/direnv/shell]: https://github.com/direnv/direnv/blob/trunk/docs/hook.md [install/nix]: https://nix.dev/install-nix [issue/1364]: https://github.com/git-bug/git-bug/issues/1364 [treefmt]: ./treefmt.nix @@ -1,8 +1,3 @@ -all: build - -GIT_COMMIT:=$(shell git rev-list -1 HEAD) -GIT_LAST_TAG:=$(shell git describe --abbrev=0 --tags 2>/dev/null || true) -GIT_EXACT_TAG:=$(shell git name-rev --name-only --tags HEAD) UNAME_S := $(shell uname -s) XARGS:=xargs -r ifeq ($(UNAME_S),Darwin) @@ -11,10 +6,10 @@ endif SYSTEM=$(shell nix eval --impure --expr 'builtins.currentSystem' --raw 2>/dev/null || echo '') -COMMANDS_PATH:=github.com/git-bug/git-bug/commands -LDFLAGS:=-X ${COMMANDS_PATH}.GitCommit="${GIT_COMMIT}" \ - -X ${COMMANDS_PATH}.GitLastTag="${GIT_LAST_TAG}" \ - -X ${COMMANDS_PATH}.GitExactTag="${GIT_EXACT_TAG}" +TAG:=$(shell git name-rev --name-only --tags HEAD) +LDFLAGS:=-X main.version="${TAG}" + +all: build .PHONY: list-checks list-checks: @@ -1,6 +1,6 @@ <div align="center"> -<img width="64px" src="https://cdn.rawgit.com/git-bug/git-bug/master/misc/logo/logo-alpha-flat-bg.svg"> +<img width="64px" src="https://cdn.rawgit.com/git-bug/git-bug/trunk/misc/logo/logo-alpha-flat-bg.svg"> # git-bug: a decentralized issue tracker diff --git a/bridge/jira/config.go b/bridge/jira/config.go index 22ce1dcad..ea9035255 100644 --- a/bridge/jira/config.go +++ b/bridge/jira/config.go @@ -15,7 +15,7 @@ const moreConfigText = ` NOTE: There are a few optional configuration values that you can additionally set in your git configuration to influence the behavior of the bridge. Please see the notes at: -https://github.com/git-bug/git-bug/blob/master/doc/jira_bridge.md +https://github.com/git-bug/git-bug/blob/trunk/doc/jira_bridge.md ` const credTypeText = ` diff --git a/cliff.toml b/cliff.toml index 9d8d38858..f87611569 100644 --- a/cliff.toml +++ b/cliff.toml @@ -102,37 +102,11 @@ sort_commits = "oldest" topo_order = true commit_preprocessors = [ - # map various older scopes to new scopes - # TODO: remove after init (because we will enforce an append-only workflow) - { pattern = '^([^\(]+)\(commands\):', replace = '$1 (cli):' }, - { pattern = '^[^\(]+\(ci\)', replace = 'ci:' }, - { pattern = '^[^\(]+\(TestCache\)', replace = 'test:' }, - { pattern = '^doc: (.+ \(#1395\))', replace = 'docs(dev-infra): $1' }, - { pattern = '^fix: (.+ \(#1403\))', replace = 'fix(completion): $1' }, - { pattern = '^docs: (correct mispelled words)', replace = 'fix(dev-infra): $1' }, - { pattern = '^(.+) \[fix\]$', replace = 'docs: $1' }, - { pattern = '^fix ', replace = 'fix: ' }, - - # remove errata from old commit messages - # TODO: remove after init (because we will enforce an append-only workflow) - { pattern = '^([^\(]+)\((?:#?\d+|opencollective|git-bug-863)\)', replace = '$1' }, - { pattern = ', fix https://.+/issues/653', replace = '' }, - # remove quotes from reversions # we do this to clean up the changelog output, since the raw message would # otherwise be surrounded in quotes { pattern = '^[Rr]evert: "(.+)"', replace = 'revert: $1' }, - # convert quotes in subjects to graves - # TODO: remove after init (because we will enforce an append-only workflow) - { pattern = '"', replace = '`' }, - - # escape backslashes - # we do this because mdformat will remove isolated backslashes, and there is a - # historical commit that contains one - # TODO: remove after init (because we will enforce an append-only workflow) - { pattern = '\\', replace = '\\' }, - # remove PR references from commit messages, to remove a hard dependency on # github. by default, we show the commit hash (although github usernames and # PR references are added in dynamically during release, for the changes diff --git a/commands/commands.go b/commands/commands.go deleted file mode 100644 index 00c7b2dc7..000000000 --- a/commands/commands.go +++ /dev/null @@ -1,80 +0,0 @@ -package commands - -import ( - "sort" - - "github.com/spf13/cobra" - - "github.com/git-bug/git-bug/commands/execenv" -) - -type commandOptions struct { - desc bool -} - -func newCommandsCommand(env *execenv.Env) *cobra.Command { - options := commandOptions{} - - cmd := &cobra.Command{ - Use: "commands", - Short: "Display available commands.", - RunE: func(cmd *cobra.Command, args []string) error { - return runCommands(env, options) - }, - } - - flags := cmd.Flags() - flags.SortFlags = false - - flags.BoolVarP(&options.desc, "pretty", "p", false, - "Output the command description as well as Markdown compatible comment", - ) - - return cmd -} - -func runCommands(env *execenv.Env, opts commandOptions) error { - first := true - - var allCmds []*cobra.Command - queue := []*cobra.Command{NewRootCommand()} - - for len(queue) > 0 { - cmd := queue[0] - queue = queue[1:] - allCmds = append(allCmds, cmd) - queue = append(queue, cmd.Commands()...) - } - - sort.Sort(commandSorterByName(allCmds)) - - for _, cmd := range allCmds { - if !first { - env.Out.Println() - } - - first = false - - if opts.desc { - env.Out.Printf("# %s\n", cmd.Short) - } - - env.Out.Print(cmd.UseLine()) - - if opts.desc { - env.Out.Println() - } - } - - if !opts.desc { - env.Out.Println() - } - - return nil -} - -type commandSorterByName []*cobra.Command - -func (c commandSorterByName) Len() int { return len(c) } -func (c commandSorterByName) Swap(i, j int) { c[i], c[j] = c[j], c[i] } -func (c commandSorterByName) Less(i, j int) bool { return c[i].CommandPath() < c[j].CommandPath() } diff --git a/commands/root.go b/commands/root.go index e966751c7..1b64b5090 100644 --- a/commands/root.go +++ b/commands/root.go @@ -1,25 +1,17 @@ -// Package commands contains the CLI commands package commands import ( - "fmt" "os" - "runtime/debug" "github.com/spf13/cobra" - bridgecmd "github.com/git-bug/git-bug/commands/bridge" - bugcmd "github.com/git-bug/git-bug/commands/bug" + "github.com/git-bug/git-bug/commands/bridge" + "github.com/git-bug/git-bug/commands/bug" "github.com/git-bug/git-bug/commands/execenv" - usercmd "github.com/git-bug/git-bug/commands/user" + "github.com/git-bug/git-bug/commands/user" ) -// These variables are initialized externally during the build. See the Makefile. -var GitCommit string -var GitLastTag string -var GitExactTag string - -func NewRootCommand() *cobra.Command { +func NewRootCommand(version string) *cobra.Command { cmd := &cobra.Command{ Use: execenv.RootCommandName, Short: "A bug tracker embedded in Git", @@ -33,7 +25,7 @@ the same git remote you are already using to collaborate with other people. PersistentPreRun: func(cmd *cobra.Command, args []string) { root := cmd.Root() - root.Version = getVersion() + root.Version = version }, // For the root command, force the execution of the PreRun @@ -75,70 +67,8 @@ the same git remote you are already using to collaborate with other people. addCmdWithGroup(newPushCommand(env), remoteGroup) addCmdWithGroup(bridgecmd.NewBridgeCommand(env), remoteGroup) - cmd.AddCommand(newCommandsCommand(env)) cmd.AddCommand(newVersionCommand(env)) cmd.AddCommand(newWipeCommand(env)) return cmd } - -func Execute() { - if err := NewRootCommand().Execute(); err != nil { - os.Exit(1) - } -} - -func getVersion() string { - if GitExactTag == "undefined" { - GitExactTag = "" - } - - if GitExactTag != "" { - // we are exactly on a tag --> release version - return GitLastTag - } - - if GitLastTag != "" { - // not exactly on a tag --> dev version - return fmt.Sprintf("%s-dev-%.10s", GitLastTag, GitCommit) - } - - // we don't have commit information, try golang build info - if commit, dirty, err := getCommitAndDirty(); err == nil { - if dirty { - return fmt.Sprintf("dev-%.10s-dirty", commit) - } - return fmt.Sprintf("dev-%.10s", commit) - } - - return "dev-unknown" -} - -func getCommitAndDirty() (commit string, dirty bool, err error) { - info, ok := debug.ReadBuildInfo() - if !ok { - return "", false, fmt.Errorf("unable to read build info") - } - - var commitFound bool - - // get the commit and modified status - // (that is the flag for repository dirty or not) - for _, kv := range info.Settings { - switch kv.Key { - case "vcs.revision": - commit = kv.Value - commitFound = true - case "vcs.modified": - if kv.Value == "true" { - dirty = true - } - } - } - - if !commitFound { - return "", false, fmt.Errorf("no commit found") - } - - return commit, dirty, nil -} diff --git a/commands/version.go b/commands/version.go index 189a2e350..ffa4a180a 100644 --- a/commands/version.go +++ b/commands/version.go @@ -1,63 +1,66 @@ package commands import ( - "runtime" + "log/slog" "github.com/spf13/cobra" "github.com/git-bug/git-bug/commands/execenv" ) -type versionOptions struct { - number bool - commit bool - all bool -} +// TODO: 0.12.0: remove deprecated build vars +var ( + GitCommit string + GitLastTag string + GitExactTag string +) func newVersionCommand(env *execenv.Env) *cobra.Command { - options := versionOptions{} + return &cobra.Command{ + Use: "version", + Short: "Print version information", + Example: "git bug version", + Long: ` +Print version information. - cmd := &cobra.Command{ - Use: "version", - Short: "Show git-bug version information", - Run: func(cmd *cobra.Command, args []string) { - runVersion(env, options, cmd.Root()) - }, - } +Format: + git-bug <version> [commit[/dirty]] <compiler version> <platform> <arch> - flags := cmd.Flags() - flags.SortFlags = false +Format Description: + <version> may be one of: + - A semantic version string, prefixed with a "v", e.g. v1.2.3 + - "undefined" (if not provided, or built with an invalid version string) - flags.BoolVarP(&options.number, "number", "n", false, - "Only show the version number", - ) - flags.BoolVarP(&options.commit, "commit", "c", false, - "Only show the commit hash", - ) - flags.BoolVarP(&options.all, "all", "a", false, - "Show all version information", - ) + [commit], if present, is the commit hash that was checked out during the + build. This may be suffixed with '/dirty' if there were local file + modifications. This is indicative of your build being patched, or modified in + some way from the commit. - return cmd -} + <compiler version> is the version of the go compiler used for the build. -func runVersion(env *execenv.Env, opts versionOptions, root *cobra.Command) { - if opts.all { - env.Out.Printf("%s version: %s\n", execenv.RootCommandName, root.Version) - env.Out.Printf("System version: %s/%s\n", runtime.GOARCH, runtime.GOOS) - env.Out.Printf("Golang version: %s\n", runtime.Version()) - return - } + <platform> is the target platform (GOOS). - if opts.number { - env.Out.Println(root.Version) - return + <arch> is the target architecture (GOARCH). +`, + Run: func(cmd *cobra.Command, args []string) { + defer warnDeprecated() + env.Out.Printf("%s %s", execenv.RootCommandName, cmd.Root().Version) + }, } +} - if opts.commit { - env.Out.Println(GitCommit) - return +// warnDeprecated warns about deprecated build variables +// TODO: 0.12.0: remove support for old build tags +func warnDeprecated() { + msg := "please contact your package maintainer" + reason := "deprecated build variable" + if GitLastTag != "" { + slog.Warn(msg, "reason", reason, "name", "GitLastTag", "value", GitLastTag) + } + if GitExactTag != "" { + slog.Warn(msg, "reason", reason, "name", "GitExactTag", "value", GitExactTag) + } + if GitCommit != "" { + slog.Warn(msg, "reason", reason, "name", "GitCommit", "value", GitCommit) } - - env.Out.Printf("%s version: %s\n", execenv.RootCommandName, root.Version) } diff --git a/doc/generate.go b/doc/generate.go index 0001f1a77..005d9df76 100644 --- a/doc/generate.go +++ b/doc/generate.go @@ -34,7 +34,7 @@ func main() { wg.Add(1) go func(name string, f func(*cobra.Command) error) { defer wg.Done() - root := commands.NewRootCommand() + root := commands.NewRootCommand("") err := f(root) if err != nil { fmt.Printf(" - %s: FATAL\n", name) diff --git a/doc/man/git-bug-commands.1 b/doc/man/git-bug-commands.1 deleted file mode 100644 index 58d24fc47..000000000 --- a/doc/man/git-bug-commands.1 +++ /dev/null @@ -1,26 +0,0 @@ -.nh -.TH "GIT-BUG" "1" "Apr 2019" "Generated from git-bug's source code" "" - -.SH NAME -git-bug-commands - Display available commands. - - -.SH SYNOPSIS -\fBgit-bug commands [flags]\fP - - -.SH DESCRIPTION -Display available commands. - - -.SH OPTIONS -\fB-p\fP, \fB--pretty\fP[=false] - Output the command description as well as Markdown compatible comment - -.PP -\fB-h\fP, \fB--help\fP[=false] - help for commands - - -.SH SEE ALSO -\fBgit-bug(1)\fP diff --git a/doc/man/git-bug-version.1 b/doc/man/git-bug-version.1 index 7183b696e..988849e8a 100644 --- a/doc/man/git-bug-version.1 +++ b/doc/man/git-bug-version.1 @@ -2,7 +2,7 @@ .TH "GIT-BUG" "1" "Apr 2019" "Generated from git-bug's source code" "" .SH NAME -git-bug-version - Show git-bug version information +git-bug-version - Print version information .SH SYNOPSIS @@ -10,25 +10,44 @@ git-bug-version - Show git-bug version information .SH DESCRIPTION -Show git-bug version information +Print version information. +.PP +Format: + git-bug [commit[/dirty]] -.SH OPTIONS -\fB-n\fP, \fB--number\fP[=false] - Only show the version number +.PP +Format Description: + may be one of: + - A semantic version string, prefixed with a "v", e.g. v1.2.3 + - "undefined" (if not provided, or built with an invalid version string) + +.PP +[commit], if present, is the commit hash that was checked out during the + build. This may be suffixed with '/dirty' if there were local file + modifications. This is indicative of your build being patched, or modified in + some way from the commit. .PP -\fB-c\fP, \fB--commit\fP[=false] - Only show the commit hash + is the version of the go compiler used for the build. .PP -\fB-a\fP, \fB--all\fP[=false] - Show all version information + is the target platform (GOOS). .PP + is the target architecture (GOARCH). + + +.SH OPTIONS \fB-h\fP, \fB--help\fP[=false] help for version +.SH EXAMPLE +.EX +git bug version +.EE + + .SH SEE ALSO \fBgit-bug(1)\fP diff --git a/doc/man/git-bug.1 b/doc/man/git-bug.1 index 24d8e8644..7320689b4 100644 --- a/doc/man/git-bug.1 +++ b/doc/man/git-bug.1 @@ -24,4 +24,4 @@ the same git remote you are already using to collaborate with other people. .SH SEE ALSO -\fBgit-bug-bridge(1)\fP, \fBgit-bug-bug(1)\fP, \fBgit-bug-commands(1)\fP, \fBgit-bug-label(1)\fP, \fBgit-bug-pull(1)\fP, \fBgit-bug-push(1)\fP, \fBgit-bug-termui(1)\fP, \fBgit-bug-user(1)\fP, \fBgit-bug-version(1)\fP, \fBgit-bug-webui(1)\fP, \fBgit-bug-wipe(1)\fP +\fBgit-bug-bridge(1)\fP, \fBgit-bug-bug(1)\fP, \fBgit-bug-label(1)\fP, \fBgit-bug-pull(1)\fP, \fBgit-bug-push(1)\fP, \fBgit-bug-termui(1)\fP, \fBgit-bug-user(1)\fP, \fBgit-bug-version(1)\fP, \fBgit-bug-webui(1)\fP, \fBgit-bug-wipe(1)\fP diff --git a/doc/md/git-bug.md b/doc/md/git-bug.md index a71d6dfb9..2ef0b7725 100644 --- a/doc/md/git-bug.md +++ b/doc/md/git-bug.md @@ -26,13 +26,12 @@ git-bug [flags] * [git-bug bridge](git-bug_bridge.md) - List bridges to other bug trackers * [git-bug bug](git-bug_bug.md) - List bugs -* [git-bug commands](git-bug_commands.md) - Display available commands. * [git-bug label](git-bug_label.md) - List valid labels * [git-bug pull](git-bug_pull.md) - Pull updates from a git remote * [git-bug push](git-bug_push.md) - Push updates to a git remote * [git-bug termui](git-bug_termui.md) - Launch the terminal UI * [git-bug user](git-bug_user.md) - List identities -* [git-bug version](git-bug_version.md) - Show git-bug version information +* [git-bug version](git-bug_version.md) - Print version information * [git-bug webui](git-bug_webui.md) - Launch the web UI * [git-bug wipe](git-bug_wipe.md) - Wipe git-bug from the git repository diff --git a/doc/md/git-bug_commands.md b/doc/md/git-bug_commands.md deleted file mode 100644 index bce599dd9..000000000 --- a/doc/md/git-bug_commands.md +++ /dev/null @@ -1,19 +0,0 @@ -## git-bug commands - -Display available commands. - -``` -git-bug commands [flags] -``` - -### Options - -``` - -p, --pretty Output the command description as well as Markdown compatible comment - -h, --help help for commands -``` - -### SEE ALSO - -* [git-bug](git-bug.md) - A bug tracker embedded in Git - diff --git a/doc/md/git-bug_version.md b/doc/md/git-bug_version.md index ceba8790f..a2569aff1 100644 --- a/doc/md/git-bug_version.md +++ b/doc/md/git-bug_version.md @@ -1,18 +1,46 @@ ## git-bug version -Show git-bug version information +Print version information + +### Synopsis + + +Print version information. + +Format: + git-bug <version> [commit[/dirty]] <compiler version> <platform> <arch> + +Format Description: + <version> may be one of: + - A semantic version string, prefixed with a "v", e.g. v1.2.3 + - "undefined" (if not provided, or built with an invalid version string) + + [commit], if present, is the commit hash that was checked out during the + build. This may be suffixed with '/dirty' if there were local file + modifications. This is indicative of your build being patched, or modified in + some way from the commit. + + <compiler version> is the version of the go compiler used for the build. + + <platform> is the target platform (GOOS). + + <arch> is the target architecture (GOARCH). + ``` git-bug version [flags] ``` +### Examples + +``` +git bug version +``` + ### Options ``` - -n, --number Only show the version number - -c, --commit Only show the commit hash - -a, --all Show all version information - -h, --help help for version + -h, --help help for version ``` ### SEE ALSO diff --git a/entity/dag/example_test.go b/entity/dag/example_test.go index 3ffdb4fcf..cb2a53835 100644 --- a/entity/dag/example_test.go +++ b/entity/dag/example_test.go @@ -13,7 +13,7 @@ import ( ) // Note: you can find explanations about the underlying data model here: -// https://github.com/git-bug/git-bug/blob/master/doc/design/data-model.md +// https://github.com/git-bug/git-bug/blob/trunk/doc/design/data-model.md // This file explains how to define a replicated data structure, stored in and using git as a medium for // synchronisation. To do this, we'll use the entity/dag package, which will do all the complex handling. @@ -4,10 +4,6 @@ go 1.24.0 toolchain go1.24.2 -// caused by github.com/blevesearch/bleve@v1.0.14 -// caused by github.com/couchbase/vellum@v1.0.2 -replace github.com/willf/bitset v1.1.11 => github.com/bits-and-blooms/bitset v1.1.11 - require ( github.com/99designs/gqlgen v0.17.73 github.com/99designs/keyring v1.2.2 @@ -15,7 +11,7 @@ require ( github.com/ProtonMail/go-crypto v1.1.3 github.com/araddon/dateparse v0.0.0-20210429162001-6b43995a97de github.com/awesome-gocui/gocui v1.1.0 - github.com/blevesearch/bleve v1.0.14 + github.com/blevesearch/bleve/v2 v2.5.1 github.com/dustin/go-humanize v1.0.1 github.com/fatih/color v1.17.0 github.com/go-git/go-billy/v5 v5.6.0 @@ -42,29 +38,34 @@ require ( golang.org/x/text v0.24.0 ) -tool github.com/99designs/gqlgen - require ( dario.cat/mergo v1.0.1 // indirect github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4 // indirect github.com/Microsoft/go-winio v0.6.2 // indirect - github.com/RoaringBitmap/roaring v1.9.4 // indirect + github.com/RoaringBitmap/roaring/v2 v2.4.5 // indirect github.com/VividCortex/ewma v1.2.0 // indirect github.com/acarl005/stripansi v0.0.0-20180116102854-5a71ef0e047d // indirect github.com/agnivade/levenshtein v1.2.1 // indirect - github.com/bits-and-blooms/bitset v1.13.0 // indirect + github.com/bits-and-blooms/bitset v1.22.0 // indirect + github.com/blevesearch/bleve_index_api v1.2.8 // indirect + github.com/blevesearch/geo v0.2.3 // indirect + github.com/blevesearch/go-faiss v1.0.25 // indirect github.com/blevesearch/go-porterstemmer v1.0.3 // indirect + github.com/blevesearch/gtreap v0.1.1 // indirect github.com/blevesearch/mmap-go v1.0.4 // indirect + github.com/blevesearch/scorch_segment_api/v2 v2.3.10 // indirect github.com/blevesearch/segment v0.9.1 // indirect github.com/blevesearch/snowballstem v0.9.0 // indirect - github.com/blevesearch/zap/v11 v11.0.14 // indirect - github.com/blevesearch/zap/v12 v12.0.14 // indirect - github.com/blevesearch/zap/v13 v13.0.6 // indirect - github.com/blevesearch/zap/v14 v14.0.5 // indirect - github.com/blevesearch/zap/v15 v15.0.3 // indirect - github.com/cloudflare/circl v1.4.0 // indirect + github.com/blevesearch/upsidedown_store_api v1.0.2 // indirect + github.com/blevesearch/vellum v1.1.0 // indirect + github.com/blevesearch/zapx/v11 v11.4.2 // indirect + github.com/blevesearch/zapx/v12 v12.4.2 // indirect + github.com/blevesearch/zapx/v13 v13.4.2 // indirect + github.com/blevesearch/zapx/v14 v14.4.2 // indirect + github.com/blevesearch/zapx/v15 v15.4.2 // indirect + github.com/blevesearch/zapx/v16 v16.2.3 // indirect + github.com/cloudflare/circl v1.6.1 // indirect github.com/corpix/uarand v0.2.0 // indirect - github.com/couchbase/vellum v1.0.2 // indirect github.com/cpuguy83/go-md2man/v2 v2.0.5 // indirect github.com/cyphar/filepath-securejoin v0.3.3 // indirect github.com/danieljoos/wincred v1.2.2 // indirect @@ -87,6 +88,7 @@ require ( github.com/hashicorp/go-retryablehttp v0.7.7 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 // indirect + github.com/json-iterator/go v0.0.0-20171115153421-f7279a603ede // indirect github.com/kevinburke/ssh_config v1.2.0 // indirect github.com/lucasb-eyer/go-colorful v1.2.0 // indirect github.com/mattn/go-colorable v0.1.14 // indirect @@ -101,15 +103,13 @@ require ( github.com/shurcooL/graphql v0.0.0-20230722043721-ed46e5a46466 // indirect github.com/skeema/knownhosts v1.3.0 // indirect github.com/sosodev/duration v1.3.1 // indirect - github.com/spf13/pflag v1.0.5 // indirect - github.com/steveyen/gtreap v0.1.0 // indirect + github.com/spf13/pflag v1.0.6 // indirect github.com/stretchr/objx v0.5.2 // indirect github.com/urfave/cli/v2 v2.27.6 // indirect - github.com/willf/bitset v1.1.11 // indirect github.com/xanzy/ssh-agent v0.3.3 // indirect github.com/xrash/smetrics v0.0.0-20240521201337-686a1a2994c1 // indirect - go.etcd.io/bbolt v1.3.10 // indirect - golang.org/x/mod v0.24.0 // indirect + go.etcd.io/bbolt v1.4.0 // indirect + golang.org/x/mod v0.24.0 golang.org/x/net v0.39.0 golang.org/x/telemetry v0.0.0-20240723021908-ccdfb411a0c4 // indirect golang.org/x/term v0.31.0 @@ -120,3 +120,5 @@ require ( gopkg.in/warnings.v0 v0.1.2 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect ) + +tool github.com/99designs/gqlgen @@ -6,7 +6,6 @@ github.com/99designs/gqlgen v0.17.73 h1:A3Ki+rHWqKbAOlg5fxiZBnz6OjW3nwupDHEG15gE github.com/99designs/gqlgen v0.17.73/go.mod h1:2RyGWjy2k7W9jxrs8MOQthXGkD3L3oGr0jXW3Pu8lGg= github.com/99designs/keyring v1.2.2 h1:pZd3neh/EmUzWONb35LxQfvuY7kiSXAq3HQd97+XBn0= github.com/99designs/keyring v1.2.2/go.mod h1:wes/FrByc8j7lFOAGLGSNEg8f/PaI3cgTBqhFkHUrPk= -github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/MichaelMure/go-term-text v0.3.1 h1:Kw9kZanyZWiCHOYu9v/8pWEgDQ6UVN9/ix2Vd2zzWf0= github.com/MichaelMure/go-term-text v0.3.1/go.mod h1:QgVjAEDUnRMlzpS6ky5CGblux7ebeiLnuy9dAaFZu8o= github.com/Microsoft/go-winio v0.5.2/go.mod h1:WpS1mjBmmwHBEWmogvA2mj8546UReBk4v8QkMxJ6pZY= @@ -16,9 +15,8 @@ github.com/ProtonMail/go-crypto v1.1.3 h1:nRBOetoydLeUb4nHajyO2bKqMLfWQ/ZPwkXqXx github.com/ProtonMail/go-crypto v1.1.3/go.mod h1:rA3QumHc/FZ8pAHreoekgiAbzpNsfQAosU5td4SnOrE= github.com/PuerkitoBio/goquery v1.10.3 h1:pFYcNSqHxBD06Fpj/KsbStFRsgRATgnf3LeXiUkhzPo= github.com/PuerkitoBio/goquery v1.10.3/go.mod h1:tMUX0zDMHXYlAQk6p35XxQMqMweEKB7iK7iLNd4RH4Y= -github.com/RoaringBitmap/roaring v0.4.23/go.mod h1:D0gp8kJQgE1A4LQ5wFLggQEyvDi06Mq5mKs52e1TwOo= -github.com/RoaringBitmap/roaring v1.9.4 h1:yhEIoH4YezLYT04s1nHehNO64EKFTop/wBhxv2QzDdQ= -github.com/RoaringBitmap/roaring v1.9.4/go.mod h1:6AXUsoIEzDTFFQCe1RbGA6uFONMhvejWj5rqITANK90= +github.com/RoaringBitmap/roaring/v2 v2.4.5 h1:uGrrMreGjvAtTBobc0g5IrW1D5ldxDQYe2JW2gggRdg= +github.com/RoaringBitmap/roaring/v2 v2.4.5/go.mod h1:FiJcsfkGje/nZBZgCu0ZxCPOKD/hVXDS2dXi7/eUFE0= github.com/VividCortex/ewma v1.2.0 h1:f58SaIzcDXrSy3kWaHNvuJgJ3Nmz59Zji6XoJR/q1ow= github.com/VividCortex/ewma v1.2.0/go.mod h1:nz4BbCtbLyFDeC9SUHbtcT5644juEuWfUAUnGx7j5l4= github.com/acarl005/stripansi v0.0.0-20180116102854-5a71ef0e047d h1:licZJFw2RwpHMqeKTCYkitsPqHNxTmd4SNR5r94FGM8= @@ -35,62 +33,58 @@ github.com/araddon/dateparse v0.0.0-20210429162001-6b43995a97de h1:FxWPpzIjnTlhP github.com/araddon/dateparse v0.0.0-20210429162001-6b43995a97de/go.mod h1:DCaWoUhZrYW9p1lxo/cm8EmUOOzAPSEZNGF2DK1dJgw= github.com/arbovm/levenshtein v0.0.0-20160628152529-48b4e1c0c4d0 h1:jfIu9sQUG6Ig+0+Ap1h4unLjW6YQJpKZVmUzxsD4E/Q= github.com/arbovm/levenshtein v0.0.0-20160628152529-48b4e1c0c4d0/go.mod h1:t2tdKJDJF9BV14lnkjHmOQgcvEKgtqs5a1N3LNdJhGE= -github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8= github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5 h1:0CwZNZbxp69SHPdPJAN/hZIm0C4OItdklCFmMRWYpio= github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs= github.com/awesome-gocui/gocui v1.1.0 h1:db2j7yFEoHZjpQFeE2xqiatS8bm1lO3THeLwE6MzOII= github.com/awesome-gocui/gocui v1.1.0/go.mod h1:M2BXkrp7PR97CKnPRT7Rk0+rtswChPtksw/vRAESGpg= -github.com/bits-and-blooms/bitset v1.1.11 h1:12SusVDSQ/iJ9qaeM3yTcLLdEyqtpl35b80STAj06Fg= -github.com/bits-and-blooms/bitset v1.1.11/go.mod h1:83CECat5yLh5zVOf4P1ErAgKA5UDvKtgyUABdr3+MjI= github.com/bits-and-blooms/bitset v1.12.0/go.mod h1:7hO7Gc7Pp1vODcmWvKMRA9BNmbv6a/7QIWpPxHddWR8= -github.com/bits-and-blooms/bitset v1.13.0 h1:bAQ9OPNFYbGHV6Nez0tmNI0RiEu7/hxlYJRUA0wFAVE= -github.com/bits-and-blooms/bitset v1.13.0/go.mod h1:7hO7Gc7Pp1vODcmWvKMRA9BNmbv6a/7QIWpPxHddWR8= -github.com/blevesearch/bleve v1.0.14 h1:Q8r+fHTt35jtGXJUM0ULwM3Tzg+MRfyai4ZkWDy2xO4= -github.com/blevesearch/bleve v1.0.14/go.mod h1:e/LJTr+E7EaoVdkQZTfoz7dt4KoDNvDbLb8MSKuNTLQ= -github.com/blevesearch/blevex v1.0.0 h1:pnilj2Qi3YSEGdWgLj1Pn9Io7ukfXPoQcpAI1Bv8n/o= -github.com/blevesearch/blevex v1.0.0/go.mod h1:2rNVqoG2BZI8t1/P1awgTKnGlx5MP9ZbtEciQaNhswc= -github.com/blevesearch/cld2 v0.0.0-20200327141045-8b5f551d37f5/go.mod h1:PN0QNTLs9+j1bKy3d/GB/59wsNBFC4sWLWG3k69lWbc= +github.com/bits-and-blooms/bitset v1.22.0 h1:Tquv9S8+SGaS3EhyA+up3FXzmkhxPGjQQCkcs2uw7w4= +github.com/bits-and-blooms/bitset v1.22.0/go.mod h1:7hO7Gc7Pp1vODcmWvKMRA9BNmbv6a/7QIWpPxHddWR8= +github.com/blevesearch/bleve/v2 v2.5.1 h1:cc/O++W2Hcjp1SU5ETHeE+QYWv2oV88ldYEPowdmg8M= +github.com/blevesearch/bleve/v2 v2.5.1/go.mod h1:9g/wnbWKm9AgXrU8Ecqi+IDdqjUHWymwkQRDg+5tafU= +github.com/blevesearch/bleve_index_api v1.2.8 h1:Y98Pu5/MdlkRyLM0qDHostYo7i+Vv1cDNhqTeR4Sy6Y= +github.com/blevesearch/bleve_index_api v1.2.8/go.mod h1:rKQDl4u51uwafZxFrPD1R7xFOwKnzZW7s/LSeK4lgo0= +github.com/blevesearch/geo v0.2.3 h1:K9/vbGI9ehlXdxjxDRJtoAMt7zGAsMIzc6n8zWcwnhg= +github.com/blevesearch/geo v0.2.3/go.mod h1:K56Q33AzXt2YExVHGObtmRSFYZKYGv0JEN5mdacJJR8= +github.com/blevesearch/go-faiss v1.0.25 h1:lel1rkOUGbT1CJ0YgzKwC7k+XH0XVBHnCVWahdCXk4U= +github.com/blevesearch/go-faiss v1.0.25/go.mod h1:OMGQwOaRRYxrmeNdMrXJPvVx8gBnvE5RYrr0BahNnkk= github.com/blevesearch/go-porterstemmer v1.0.3 h1:GtmsqID0aZdCSNiY8SkuPJ12pD4jI+DdXTAn4YRcHCo= github.com/blevesearch/go-porterstemmer v1.0.3/go.mod h1:angGc5Ht+k2xhJdZi511LtmxuEf0OVpvUUNrwmM1P7M= -github.com/blevesearch/mmap-go v1.0.2/go.mod h1:ol2qBqYaOUsGdm7aRMRrYGgPvnwLe6Y+7LMvAB5IbSA= +github.com/blevesearch/gtreap v0.1.1 h1:2JWigFrzDMR+42WGIN/V2p0cUvn4UP3C4Q5nmaZGW8Y= +github.com/blevesearch/gtreap v0.1.1/go.mod h1:QaQyDRAT51sotthUWAH4Sj08awFSSWzgYICSZ3w0tYk= github.com/blevesearch/mmap-go v1.0.4 h1:OVhDhT5B/M1HNPpYPBKIEJaD0F3Si+CrEKULGCDPWmc= github.com/blevesearch/mmap-go v1.0.4/go.mod h1:EWmEAOmdAS9z/pi/+Toxu99DnsbhG1TIxUoRmJw/pSs= -github.com/blevesearch/segment v0.9.0/go.mod h1:9PfHYUdQCgHktBgvtUOF4x+pc4/l8rdH0u5spnW85UQ= +github.com/blevesearch/scorch_segment_api/v2 v2.3.10 h1:Yqk0XD1mE0fDZAJXTjawJ8If/85JxnLd8v5vG/jWE/s= +github.com/blevesearch/scorch_segment_api/v2 v2.3.10/go.mod h1:Z3e6ChN3qyN35yaQpl00MfI5s8AxUJbpTR/DL8QOQ+8= github.com/blevesearch/segment v0.9.1 h1:+dThDy+Lvgj5JMxhmOVlgFfkUtZV2kw49xax4+jTfSU= github.com/blevesearch/segment v0.9.1/go.mod h1:zN21iLm7+GnBHWTao9I+Au/7MBiL8pPFtJBJTsk6kQw= github.com/blevesearch/snowballstem v0.9.0 h1:lMQ189YspGP6sXvZQ4WZ+MLawfV8wOmPoD/iWeNXm8s= github.com/blevesearch/snowballstem v0.9.0/go.mod h1:PivSj3JMc8WuaFkTSRDW2SlrulNWPl4ABg1tC/hlgLs= -github.com/blevesearch/zap/v11 v11.0.14 h1:IrDAvtlzDylh6H2QCmS0OGcN9Hpf6mISJlfKjcwJs7k= -github.com/blevesearch/zap/v11 v11.0.14/go.mod h1:MUEZh6VHGXv1PKx3WnCbdP404LGG2IZVa/L66pyFwnY= -github.com/blevesearch/zap/v12 v12.0.14 h1:2o9iRtl1xaRjsJ1xcqTyLX414qPAwykHNV7wNVmbp3w= -github.com/blevesearch/zap/v12 v12.0.14/go.mod h1:rOnuZOiMKPQj18AEKEHJxuI14236tTQ1ZJz4PAnWlUg= -github.com/blevesearch/zap/v13 v13.0.6 h1:r+VNSVImi9cBhTNNR+Kfl5uiGy8kIbb0JMz/h8r6+O4= -github.com/blevesearch/zap/v13 v13.0.6/go.mod h1:L89gsjdRKGyGrRN6nCpIScCvvkyxvmeDCwZRcjjPCrw= -github.com/blevesearch/zap/v14 v14.0.5 h1:NdcT+81Nvmp2zL+NhwSvGSLh7xNgGL8QRVZ67njR0NU= -github.com/blevesearch/zap/v14 v14.0.5/go.mod h1:bWe8S7tRrSBTIaZ6cLRbgNH4TUDaC9LZSpRGs85AsGY= -github.com/blevesearch/zap/v15 v15.0.3 h1:Ylj8Oe+mo0P25tr9iLPp33lN6d4qcztGjaIsP51UxaY= -github.com/blevesearch/zap/v15 v15.0.3/go.mod h1:iuwQrImsh1WjWJ0Ue2kBqY83a0rFtJTqfa9fp1rbVVU= -github.com/cloudflare/circl v1.4.0 h1:BV7h5MgrktNzytKmWjpOtdYrf0lkkbF8YMlBGPhJQrY= -github.com/cloudflare/circl v1.4.0/go.mod h1:PDRU+oXvdD7KCtgKxW95M5Z8BpSCJXQORiZFnBQS5QU= -github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= -github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8NzMklzPG4d5KIOhIy30Tk= -github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= +github.com/blevesearch/upsidedown_store_api v1.0.2 h1:U53Q6YoWEARVLd1OYNc9kvhBMGZzVrdmaozG2MfoB+A= +github.com/blevesearch/upsidedown_store_api v1.0.2/go.mod h1:M01mh3Gpfy56Ps/UXHjEO/knbqyQ1Oamg8If49gRwrQ= +github.com/blevesearch/vellum v1.1.0 h1:CinkGyIsgVlYf8Y2LUQHvdelgXr6PYuvoDIajq6yR9w= +github.com/blevesearch/vellum v1.1.0/go.mod h1:QgwWryE8ThtNPxtgWJof5ndPfx0/YMBh+W2weHKPw8Y= +github.com/blevesearch/zapx/v11 v11.4.2 h1:l46SV+b0gFN+Rw3wUI1YdMWdSAVhskYuvxlcgpQFljs= +github.com/blevesearch/zapx/v11 v11.4.2/go.mod h1:4gdeyy9oGa/lLa6D34R9daXNUvfMPZqUYjPwiLmekwc= +github.com/blevesearch/zapx/v12 v12.4.2 h1:fzRbhllQmEMUuAQ7zBuMvKRlcPA5ESTgWlDEoB9uQNE= +github.com/blevesearch/zapx/v12 v12.4.2/go.mod h1:TdFmr7afSz1hFh/SIBCCZvcLfzYvievIH6aEISCte58= +github.com/blevesearch/zapx/v13 v13.4.2 h1:46PIZCO/ZuKZYgxI8Y7lOJqX3Irkc3N8W82QTK3MVks= +github.com/blevesearch/zapx/v13 v13.4.2/go.mod h1:knK8z2NdQHlb5ot/uj8wuvOq5PhDGjNYQQy0QDnopZk= +github.com/blevesearch/zapx/v14 v14.4.2 h1:2SGHakVKd+TrtEqpfeq8X+So5PShQ5nW6GNxT7fWYz0= +github.com/blevesearch/zapx/v14 v14.4.2/go.mod h1:rz0XNb/OZSMjNorufDGSpFpjoFKhXmppH9Hi7a877D8= +github.com/blevesearch/zapx/v15 v15.4.2 h1:sWxpDE0QQOTjyxYbAVjt3+0ieu8NCE0fDRaFxEsp31k= +github.com/blevesearch/zapx/v15 v15.4.2/go.mod h1:1pssev/59FsuWcgSnTa0OeEpOzmhtmr/0/11H0Z8+Nw= +github.com/blevesearch/zapx/v16 v16.2.3 h1:7Y0r+a3diEvlazsncexq1qoFOcBd64xwMS7aDm4lo1s= +github.com/blevesearch/zapx/v16 v16.2.3/go.mod h1:wVJ+GtURAaRG9KQAMNYyklq0egV+XJlGcXNCE0OFjjA= +github.com/cloudflare/circl v1.6.1 h1:zqIqSPIndyBh1bjLVVDHMPpVKqp8Su/V+6MeDzzQBQ0= +github.com/cloudflare/circl v1.6.1/go.mod h1:uddAzsPgqdMAYatqJ0lsjX1oECcQLIlRpzZh3pJrofs= github.com/corpix/uarand v0.2.0 h1:U98xXwud/AVuCpkpgfPF7J5TQgr7R5tqT8VZP5KWbzE= github.com/corpix/uarand v0.2.0/go.mod h1:/3Z1QIqWkDIhf6XWn/08/uMHoQ8JUoTIKc2iPchBOmM= -github.com/couchbase/ghistogram v0.1.0/go.mod h1:s1Jhy76zqfEecpNWJfWUiKZookAFaiGOEoyzgHt9i7k= -github.com/couchbase/moss v0.1.0/go.mod h1:9MaHIaRuy9pvLPUJxB8sh8OrLfyDczECVL37grCIubs= -github.com/couchbase/vellum v1.0.2 h1:BrbP0NKiyDdndMPec8Jjhy0U47CZ0Lgx3xUC2r9rZqw= -github.com/couchbase/vellum v1.0.2/go.mod h1:FcwrEivFpNi24R3jLOs3n+fs5RnuQnQqCLBJ1uAg1W4= -github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE= github.com/cpuguy83/go-md2man/v2 v2.0.4/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/cpuguy83/go-md2man/v2 v2.0.5 h1:ZtcqGrnekaHpVLArFSe4HK5DoKx1T0rq2DwVB0alcyc= github.com/cpuguy83/go-md2man/v2 v2.0.5/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/cyphar/filepath-securejoin v0.3.3 h1:lofZkCEVFIBe0KcdQOzFs8Soy9oaHOWl4gGtPI+gCFc= github.com/cyphar/filepath-securejoin v0.3.3/go.mod h1:8s/MCNJREmFK0H02MF6Ihv1nakJe4L/w3WZLHNkvlYM= -github.com/cznic/b v0.0.0-20181122101859-a26611c4d92d h1:SwD98825d6bdB+pEuTxWOXiSjBrHdOl/UVp75eI7JT8= -github.com/cznic/b v0.0.0-20181122101859-a26611c4d92d/go.mod h1:URriBxXwVq5ijiJ12C7iIZqlA69nTlI+LgI6/pwftG8= -github.com/cznic/mathutil v0.0.0-20181122101859-297441e03548/go.mod h1:e6NPNENfs9mPDVNRekM7lKScauxd5kXTr1Mfyig6TDM= -github.com/cznic/strutil v0.0.0-20181122101858-275e90344537/go.mod h1:AHHPPPXTw0h6pVabbcbyGRK1DckRn7r/STdZEeIDzZc= github.com/danieljoos/wincred v1.2.2 h1:774zMFJrqaeYCK2W57BgAem/MLi6mtSE47MB6BOJ0i0= github.com/danieljoos/wincred v1.2.2/go.mod h1:w7w4Utbrz8lqeMbDAK0lkNJUv5sAOkFi7nd/ogr0Uh8= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= @@ -106,12 +100,8 @@ github.com/elazarl/goproxy v1.2.1 h1:njjgvO6cRG9rIqN2ebkqy6cQz2Njkx7Fsfv/zIZqgug github.com/elazarl/goproxy v1.2.1/go.mod h1:YfEbZtqP4AetfO6d40vWchF3znWX7C7Vd6ZMfdL8z64= github.com/emirpasic/gods v1.18.1 h1:FXtiHYKDGKCW2KzwZKx0iC0PQmdlorYgdFG9jPXJ1Bc= github.com/emirpasic/gods v1.18.1/go.mod h1:8tpGGwCnJ5H4r6BWwaV6OrWmMoPhUl5jm/FMNAnJvWQ= -github.com/facebookgo/ensure v0.0.0-20200202191622-63f1cf65ac4c/go.mod h1:Yg+htXGokKKdzcwhuNDwVvN+uBxDGXJ7G/VN1d8fa64= -github.com/facebookgo/stack v0.0.0-20160209184415-751773369052/go.mod h1:UbMTZqLaRiH3MsBH8va0n7s1pQYcu3uTb8G4tygF4Zg= -github.com/facebookgo/subset v0.0.0-20200203212716-c811ad88dec4/go.mod h1:5tD+neXqOorC30/tWg0LCSkrqj/AR6gu8yY8/fpw1q0= github.com/fatih/color v1.17.0 h1:GlRw1BRJxkpqUCBKzKOw098ed57fEsKeNjpTe3cSjK4= github.com/fatih/color v1.17.0/go.mod h1:YZ7TlrGPkiz6ku9fK3TLD/pl3CpsiFyu8N92HLgmosI= -github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/gdamore/encoding v1.0.0/go.mod h1:alR0ol34c49FCSBLjhosxzcPHQbf2trDkoo5dl+VrEg= github.com/gdamore/encoding v1.0.1 h1:YzKZckdBL6jVt2Gc+5p82qhrGiqMdG/eNs6Wy0u3Uhw= github.com/gdamore/encoding v1.0.1/go.mod h1:0Z0cMFinngz9kS1QfMjCP8TY7em3bZYeeklsSDPivEo= @@ -120,8 +110,6 @@ github.com/gdamore/tcell/v2 v2.7.4 h1:sg6/UnTM9jGpZU+oFYAsDahfchWAFW8Xx2yFinNSAY github.com/gdamore/tcell/v2 v2.7.4/go.mod h1:dSXtXTSK0VsW1biw65DZLZ2NKr7j0qP/0J7ONmsraWg= github.com/gliderlabs/ssh v0.3.8 h1:a4YXD1V7xMF9g5nTkdfnja3Sxy1PVDCj1Zg4Wb8vY6c= github.com/gliderlabs/ssh v0.3.8/go.mod h1:xYoytBv1sV0aL3CavoDuJIQNURXkkfPA/wxQ1pL1fAU= -github.com/glycerine/go-unsnap-stream v0.0.0-20181221182339-f9677308dec2/go.mod h1:/20jfyN9Y5QPEAprSgKAUr+glWDY39ZiUEAYOEv5dsE= -github.com/glycerine/goconvey v0.0.0-20190410193231-58a59202ab31/go.mod h1:Ogl1Tioa0aV7gstGFO7KhffUsb9M4ydbEbbxpcEDc24= github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376 h1:+zs/tPmkDkHx3U66DAb0lQFJrpS6731Oaa12ikc+DiI= github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376/go.mod h1:an3vInlBmSxCcxctByoQdvwPiA7DTK7jaaFDBTtu0ic= github.com/go-git/go-billy/v5 v5.6.0 h1:w2hPNtoehvJIxR00Vb4xX94qHQi/ApZfX+nBE2Cjio8= @@ -136,26 +124,23 @@ github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 h1:ZpnhV/YsD2/4cESfV5+ github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2/go.mod h1:bBOAhwG1umN6/6ZUMtDFBMQR8jRg9O75tm9K00oMsK4= github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da h1:oI5xCqsCo564l8iNU+DwB5epxmsaqB+rhGL0m5jtYqE= github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= -github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= -github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.5.4 h1:i7eJL8qZTpSEXOPTxNKhASYpMn+8e5Q6AdndVa1dWek= github.com/golang/protobuf v1.5.4/go.mod h1:lnTiLA8Wa4RWRcIUkrtSVa5nRhsEGBg48fD6rSs7xps= -github.com/golang/snappy v0.0.0-20180518054509-2e65f85255db/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= -github.com/golang/snappy v0.0.1/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golang/snappy v0.0.4 h1:yAGX7huGHXlcLOEtBnF4w7FQwA26wojNCwOYAEhLjQM= github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/google/go-cmdtest v0.4.1-0.20220921163831-55ab3332a786 h1:rcv+Ippz6RAtvaGgKxc+8FQIpxHgsF+HBzPyYL2cyVU= github.com/google/go-cmdtest v0.4.1-0.20220921163831-55ab3332a786/go.mod h1:apVn/GCasLZUVpAJ6oWAuyP7Ne7CEsQbTnc0plM3m+o= 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-cmp v0.7.0 h1:wk8382ETsv4JYUZwIsn6YpYiWiBsYLSJiTsyBybVuN8= +github.com/google/go-cmp v0.7.0/go.mod h1:pXiqmnSA92OHEEa9HXL2W4E7lf9JzCmGVUdgjX3N/iU= 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/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= +github.com/google/gofuzz v1.2.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/renameio v0.1.0 h1:GOZbcHa3HfsPKPlmyPyN2KEohoMXOhdMbHrvbpl2QaA= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/gopherjs/gopherjs v0.0.0-20190910122728-9d188e94fb99/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= github.com/gorilla/mux v1.8.1 h1:TuBL49tXwgrFYWhqrNgrUNEY92u81SPhu7sTdzQEiWY= github.com/gorilla/mux v1.8.1/go.mod h1:AKf9I4AEqPTmMytcMc0KkNouC66V3BtZ4qD5fmWSiMQ= github.com/gorilla/websocket v1.5.3 h1:saDtZ6Pbx/0u+bgYQ3q96pZgCzfhKXGPqt7kZ72aNNg= @@ -170,22 +155,16 @@ github.com/hashicorp/go-retryablehttp v0.7.7 h1:C8hUCYzor8PIfXHa4UrZkU4VvK8o9ISH github.com/hashicorp/go-retryablehttp v0.7.7/go.mod h1:pkQpWZeYWskR+D1tR2O5OcBFOxfA7DoAO6xtkuQnHTk= github.com/hashicorp/golang-lru/v2 v2.0.7 h1:a+bsQ5rvGLjzHuww6tVxozPZFVghXaHOwFs4luLUK2k= github.com/hashicorp/golang-lru/v2 v2.0.7/go.mod h1:QeFd9opnmA6QUJc5vARoKUSoFhyfM2/ZepoAG6RGpeM= -github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= -github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= github.com/icrowley/fake v0.0.0-20240710202011-f797eb4a99c0 h1:ufr2e4uIgz/Ft0RPudkFMyVrp77buvTFxqoDvwNGVSk= github.com/icrowley/fake v0.0.0-20240710202011-f797eb4a99c0/go.mod h1:dQ6TM/OGAe+cMws81eTe4Btv1dKxfPZ2CX+YaAFAPN4= -github.com/ikawaha/kagome.ipadic v1.1.2/go.mod h1:DPSBbU0czaJhAb/5uKQZHMc9MTVRpDugJfX+HddPHHg= -github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8= github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 h1:BQSFePA1RWJOlocH6Fxy8MmwDt+yVQYULKfN0RoTN8A= github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99/go.mod h1:1lJo3i6rXxKeerYnT8Nvf0QmHCRC1n8sfWVwXF2Frvo= -github.com/jmhodges/levigo v1.0.0 h1:q5EC36kV79HWeTBWsod3mG11EgStG3qArTKcvlksN1U= -github.com/jmhodges/levigo v1.0.0/go.mod h1:Q6Qx+uH3RAqyK4rFQroq9RL7mdkABMcfhEI+nNuzMJQ= -github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= +github.com/json-iterator/go v0.0.0-20171115153421-f7279a603ede h1:YrgBGwxMRK0Vq0WSCWFaZUnTsrA/PZE/xs1QZh+/edg= +github.com/json-iterator/go v0.0.0-20171115153421-f7279a603ede/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= github.com/kevinburke/ssh_config v1.2.0 h1:x584FjTGwHzMwvHx18PXxbBVzfnxogHaAReU4gf13a4= github.com/kevinburke/ssh_config v1.2.0/go.mod h1:CT57kijsi8u/K/BOFA39wgDQJ9CxiF4nAY/ojJ6r6mM= -github.com/kljensen/snowball v0.6.0/go.mod h1:27N7E8fVU5H68RlUmnWwZCfxgt4POBJfENGMvNRhldw= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= @@ -196,7 +175,6 @@ github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= github.com/lucasb-eyer/go-colorful v1.0.3/go.mod h1:R4dSotOR9KMtayYi1e77YzuveK+i7ruzyGqttikkLy0= github.com/lucasb-eyer/go-colorful v1.2.0 h1:1nnpGOrhyZZuNyfu1QjKiUICQ74+3FNCN69Aj6K7nkY= github.com/lucasb-eyer/go-colorful v1.2.0/go.mod h1:R4dSotOR9KMtayYi1e77YzuveK+i7ruzyGqttikkLy0= -github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= github.com/mattn/go-colorable v0.1.14 h1:9A9LHSqF/7dyVVX6g0U9cwm9pG3kP9gSzcuIPHPsaIE= github.com/mattn/go-colorable v0.1.14/go.mod h1:6LmQG8QLFO4G5z1gPvYEzlUgJ2wF+stgPZH1UqBm1s8= github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWEY= @@ -206,31 +184,21 @@ github.com/mattn/go-runewidth v0.0.12/go.mod h1:RAqKPSqVFrSLVXbA8x7dzmKdmGzieGRC github.com/mattn/go-runewidth v0.0.15/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= github.com/mattn/go-runewidth v0.0.16 h1:E5ScNMtiwvlvB5paMFdw9p4kSQzbXFikJ5SQO6TULQc= github.com/mattn/go-runewidth v0.0.16/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= -github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= -github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= -github.com/mschoch/smat v0.0.0-20160514031455-90eadee771ae/go.mod h1:qAyveg+e4CE+eKJXWVjKXM4ck2QobLqTDytGJbLLhJg= github.com/mschoch/smat v0.2.0 h1:8imxQsjDm8yFEAVBe7azKmKSgzSkZXDuKkSq9374khM= github.com/mschoch/smat v0.2.0/go.mod h1:kc9mz7DoBKqDyiRL7VZN8KvXQMWeTaVnttLRXOlotKw= github.com/mtibben/percent v0.2.1 h1:5gssi8Nqo8QU/r2pynCm+hBQHpkB/uNK7BJCFogWdzs= github.com/mtibben/percent v0.2.1/go.mod h1:KG9uO+SZkUp+VkRHsCdYQV3XSZrrSpR3O9ibNBTZrns= github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno= -github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= -github.com/onsi/ginkgo v1.7.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= -github.com/onsi/gomega v1.4.3/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY= github.com/onsi/gomega v1.34.1 h1:EUMJIKUjM8sKjYbtxQI9A4z2o+rruxnzNvpknOXie6k= github.com/onsi/gomega v1.34.1/go.mod h1:kU1QgUvBDLXBJq618Xvm2LUX6rSAfRaFRTcdOeDLwwY= -github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= github.com/phayes/freeport v0.0.0-20220201140144-74d24b5ae9f5 h1:Ii+DKncOVM8Cu1Hc+ETb5K+23HdAMvESYE3ZJ5b5cMI= github.com/phayes/freeport v0.0.0-20220201140144-74d24b5ae9f5/go.mod h1:iIss55rKnNBTvrwdmkUpLnDpZoAHvWaiq5+iMmen4AE= -github.com/philhofer/fwd v1.0.0/go.mod h1:gk3iGcWd9+svBvR0sR+KPcfE+RNWozjowpeBVG3ZVNU= github.com/pjbgf/sha1cd v0.3.0 h1:4D5XXmUUBUl/xQ6IjCkEAbqXskkq/4O7LmGn0AqMDs4= github.com/pjbgf/sha1cd v0.3.0/go.mod h1:nZ1rrWOcGJ5uZgEEVL1VUM9iRQiZvWdbZjkKyFzPPsI= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/rcrowley/go-metrics v0.0.0-20190826022208-cac0b30c2563/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= -github.com/remyoudompheng/bigfft v0.0.0-20200410134404-eec4a21b6bb0/go.mod h1:qqbHyh8v60DhA7CoWK5oRCqLrMHRGoxYCSS9EjAz6Eo= github.com/rivo/uniseg v0.1.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= github.com/rivo/uniseg v0.4.3/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88= @@ -238,7 +206,6 @@ github.com/rivo/uniseg v0.4.7 h1:WUdvkW8uEhrYfLC4ZzdpI2ztxP1I582+49Oc5Mq64VQ= github.com/rivo/uniseg v0.4.7/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88= github.com/rogpeppe/go-internal v1.11.0 h1:cWPaGQEPrBb5/AsnsZesgZZ9yb1OQ+GOISoDNXVBh4M= github.com/rogpeppe/go-internal v1.11.0/go.mod h1:ddIwULY96R17DhadqLgMfk9H9tvdUzkipdSkR5nkCZA= -github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g= github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/scylladb/termtables v0.0.0-20191203121021-c4c0b6d42ff4/go.mod h1:C1a7PQSMz9NShzorzCiG2fk9+xuCgLkPeCvMHYR2OWg= @@ -259,18 +226,11 @@ github.com/skratchdot/open-golang v0.0.0-20200116055534-eef842397966 h1:JIAuq3EE github.com/skratchdot/open-golang v0.0.0-20200116055534-eef842397966/go.mod h1:sUM3LWHvSMaG192sy56D9F7CNvL7jUJVXoqM1QKLnog= github.com/sosodev/duration v1.3.1 h1:qtHBDMQ6lvMQsL15g4aopM4HEfOaYuhWBw3NPTtlqq4= github.com/sosodev/duration v1.3.1/go.mod h1:RQIBBX0+fMLc/D9+Jb/fwvVmo0eZvDDEERAikUR6SDg= -github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ= -github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= -github.com/spf13/cobra v0.0.5/go.mod h1:3K3wKZymM7VvHMDS9+Akkh4K60UwM26emMESw8tLCHU= github.com/spf13/cobra v1.8.1 h1:e5/vxKd/rZsfSJMUX1agtjeTDf+qv1/JdBF8gg5k9ZM= github.com/spf13/cobra v1.8.1/go.mod h1:wHxEcudfqmLYa8iTfL+OuZPbBZkmvliBWKIezN3kD9Y= -github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo= -github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= -github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= -github.com/spf13/viper v1.3.2/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DMA2s= -github.com/steveyen/gtreap v0.1.0 h1:CjhzTa274PyJLJuMZwIzCO1PfC00oRa8d1Kc78bFXJM= -github.com/steveyen/gtreap v0.1.0/go.mod h1:kl/5J7XbrOmlIbYIXdRHDDE5QxHqpk0cmkT7Z4dM9/Y= +github.com/spf13/pflag v1.0.6 h1:jFzHGLGAlb3ruxLB8MhbI6A8+AQX/2eW4qeyNZXNp2o= +github.com/spf13/pflag v1.0.6/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.5.2 h1:xuMeJ0Sdp5ZMRXx/aWO6RZxdr3beISkG5/G/aIRr3pY= github.com/stretchr/objx v0.5.2/go.mod h1:FRsXN1f5AsAjCGJKqEizvkpNtU+EGNCLh3NxZ/8L+MA= @@ -279,32 +239,21 @@ github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81P github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOfJA= github.com/stretchr/testify v1.10.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= -github.com/syndtr/goleveldb v1.0.0 h1:fBdIW9lB4Iz0n9khmH8w27SJ3QEJ7+IgjPEwGSZiFdE= -github.com/syndtr/goleveldb v1.0.0/go.mod h1:ZVVdQEZoIme9iO1Ch2Jdy24qqXrMMOU6lpPAyBWyWuQ= -github.com/tebeka/snowball v0.4.2/go.mod h1:4IfL14h1lvwZcp1sfXuuc7/7yCsvVffTWxWxCLfFpYg= -github.com/tecbot/gorocksdb v0.0.0-20191217155057-f0fad39f321c h1:g+WoO5jjkqGAzHWCjJB1zZfXPIAaDpzXIEJ0eS6B5Ok= -github.com/tecbot/gorocksdb v0.0.0-20191217155057-f0fad39f321c/go.mod h1:ahpPrc7HpcfEWDQRZEmnXMzHY03mLDYMCxeDzy46i+8= -github.com/tinylib/msgp v1.1.0/go.mod h1:+d+yLhGm8mzTaHzB+wgMYrodPfmZrzkirds8fDWklFE= -github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljTbGfSG7qAOspJ7OScBnGdDN/yBr0sguwnwf0= github.com/urfave/cli/v2 v2.27.6 h1:VdRdS98FNhKZ8/Az8B7MTyGQmpIr36O1EHybx/LaZ4g= github.com/urfave/cli/v2 v2.27.6/go.mod h1:3Sevf16NykTbInEnD0yKkjDAeZDS0A6bzhBH5hrMvTQ= github.com/vbauerster/mpb/v8 v8.8.2 h1:j9D/WmvKZw0BK1etRkw8lxVMKs4KO3TgdXsQWyEyPuc= github.com/vbauerster/mpb/v8 v8.8.2/go.mod h1:JfCCrtcMsJwP6ZwMn9e5LMnNyp3TVNpUWWkN+nd4EWk= github.com/vektah/gqlparser/v2 v2.5.26 h1:REqqFkO8+SOEgZHR/eHScjjVjGS8Nk3RMO/juiTobN4= github.com/vektah/gqlparser/v2 v2.5.26/go.mod h1:D1/VCZtV3LPnQrcPBeR/q5jkSQIPti0uYCP/RI0gIeo= -github.com/willf/bitset v1.1.10/go.mod h1:RjeCKbqT1RxIR/KWY6phxZiaY1IyutSBfGjNPySAYV4= github.com/xanzy/ssh-agent v0.3.3 h1:+/15pJfg/RsTxqYcX6fHqOXZwwMP+2VyYWJeWM2qQFM= github.com/xanzy/ssh-agent v0.3.3/go.mod h1:6dzNDKs0J9rVPHPhaGCukekBHKqfl+L3KghI1Bc68Uw= -github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q= github.com/xrash/smetrics v0.0.0-20240521201337-686a1a2994c1 h1:gEOO8jv9F4OT7lGCjxCBTO/36wtF6j2nSip77qHd4x4= github.com/xrash/smetrics v0.0.0-20240521201337-686a1a2994c1/go.mod h1:Ohn+xnUBiLI6FVj/9LpzZWtj1/D6lUovWYBkxHVV3aM= github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= gitlab.com/gitlab-org/api/client-go v0.116.0 h1:Dy534gtZPMrnm3fAcmQRMadrcoUyFO4FQ4rXlSAdHAw= gitlab.com/gitlab-org/api/client-go v0.116.0/go.mod h1:B29OfnZklmaoiR7uHANh9jTyfWEgmXvZLVEnosw2Dx0= -go.etcd.io/bbolt v1.3.5/go.mod h1:G5EMThwa9y8QZGBClrRx5EY+Yw9kAhnjy3bSjsnlVTQ= -go.etcd.io/bbolt v1.3.10 h1:+BqfJTcCzTItrop8mq/lbzL8wSGtj94UO/3U31shqG0= -go.etcd.io/bbolt v1.3.10/go.mod h1:bK3UQLPJZly7IlNmV7uVHJDxfe5aK9Ll93e/74Y9oEQ= -golang.org/x/crypto v0.0.0-20181203042331-505ab145d0a9/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= +go.etcd.io/bbolt v1.4.0 h1:TU77id3TnN/zKr7CO/uk+fBCwF2jGcMuw2B/FMAzYIk= +go.etcd.io/bbolt v1.4.0/go.mod h1:AsD+OCi/qPN1giOX1aiLAha3o1U8rAz65bvN4j0sRuk= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= @@ -316,7 +265,6 @@ golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91 golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= golang.org/x/mod v0.24.0 h1:ZfthKaKaT4NrhGVZHO1/WDTwGES4De8KtWO0SIbNJMU= golang.org/x/mod v0.24.0/go.mod h1:IXM97Txy2VM4PJ3gI61r1YEk/gAj6zAHN3AdZt6S9Ww= -golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= @@ -326,19 +274,13 @@ golang.org/x/net v0.39.0 h1:ZCu7HMWDxpXpaiKdhzIfaltL9Lp31x/3fCP11bc6/fY= golang.org/x/net v0.39.0/go.mod h1:X7NRbYVEA+ewNkCNyJ513WmMdQ3BineSwVtN2zD/d+E= golang.org/x/oauth2 v0.22.0 h1:BzDx2FehcG7jJwgWLELCdmLuxk2i+x9UDpSiss2u0ZA= golang.org/x/oauth2 v0.22.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI= -golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.13.0 h1:AauUjRAJ9OSnvULf/ARrrVywoJDy0YS2AwQ98I37610= golang.org/x/sync v0.13.0/go.mod h1:1dzgHSNfp02xaA81J2MS99Qcpr2w7fw1gpm99rleRqA= -golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20181205085412-a5c9d58dba9a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20181221143128-b4a75ba826a6/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200202164722-d101bd2416d5/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -387,13 +329,11 @@ gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8 gopkg.in/check.v1 v1.0.0-20200902074654-038fdea0a05b/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= -gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= -gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= gopkg.in/warnings.v0 v0.1.2 h1:wFXVbFY8DY5/xOe1ECiWdKCzZlxgshcYVNkBHstARME= gopkg.in/warnings.v0 v0.1.2/go.mod h1:jksf8JmL6Qr/oQM2OXTHunEvvTAsrWBLb6OOjuVWRNI= -gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= +gopkg.in/yaml.v3 v3.0.0/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= @@ -4,9 +4,15 @@ package main import ( + "os" + "github.com/git-bug/git-bug/commands" ) func main() { - commands.Execute() + v, _ := getVersion() + root := commands.NewRootCommand(v) + if err := root.Execute(); err != nil { + os.Exit(1) + } } diff --git a/misc/completion/generate.go b/misc/completion/generate.go index b64c1034f..5c6468121 100644 --- a/misc/completion/generate.go +++ b/misc/completion/generate.go @@ -26,7 +26,7 @@ func main() { wg.Add(1) go func(name string, f func(*cobra.Command) error) { defer wg.Done() - root := commands.NewRootCommand() + root := commands.NewRootCommand("") err := f(root) if err != nil { fmt.Printf(" - %s: %v\n", name, err) diff --git a/repository/gogit_test.go b/repository/gogit_test.go index 21acd5dfb..7e1f6687f 100644 --- a/repository/gogit_test.go +++ b/repository/gogit_test.go @@ -71,7 +71,7 @@ func TestGoGitRepo_Indexes(t *testing.T) { require.NoError(t, err) require.NotZero(t, indexA) require.FileExists(t, filepath.Join(plainRoot, ".git", namespace, "indexes", "a", "index_meta.json")) - require.FileExists(t, filepath.Join(plainRoot, ".git", namespace, "indexes", "a", "store")) + require.FileExists(t, filepath.Join(plainRoot, ".git", namespace, "indexes", "a", "store", "root.bolt")) indexB, err := repo.GetIndex("b") require.NoError(t, err) diff --git a/repository/index_bleve.go b/repository/index_bleve.go index 401709195..1e79db1c6 100644 --- a/repository/index_bleve.go +++ b/repository/index_bleve.go @@ -7,7 +7,8 @@ import ( "sync" "unicode/utf8" - "github.com/blevesearch/bleve" + "github.com/blevesearch/bleve/v2" + "github.com/blevesearch/bleve/v2/index/upsidedown" ) var _ Index = &bleveIndex{} @@ -21,17 +22,31 @@ type bleveIndex struct { func openBleveIndex(path string) (*bleveIndex, error) { index, err := bleve.Open(path) - if err == nil { - return &bleveIndex{path: path, index: index}, nil + if err != nil { + // likely we have no index yet, we make one. + b := &bleveIndex{path: path} + return b, b.makeIndex() } - b := &bleveIndex{path: path} - err = b.makeIndex() + adv, err := index.Advanced() if err != nil { - return nil, err + _ = index.Close() + return nil, fmt.Errorf("bleve: couldn't get the advanced index to assert index type: %v", err) + } + + // if we detect the v1 format (upside-down), we force a rebuild to the v2 format (scorch) + // which is much smaller. + if _, ok := adv.(*upsidedown.UpsideDownCouch); ok { + _ = index.Close() + err = os.RemoveAll(path) + if err != nil { + return nil, err + } + b := &bleveIndex{path: path} + return b, b.makeIndex() } - return b, nil + return &bleveIndex{path: path, index: index}, nil } func (b *bleveIndex) makeIndex() error { diff --git a/version.go b/version.go new file mode 100644 index 000000000..de9bd8753 --- /dev/null +++ b/version.go @@ -0,0 +1,94 @@ +package main + +import ( + "errors" + "fmt" + "runtime/debug" + "strings" + + "github.com/git-bug/git-bug/commands" + "golang.org/x/mod/semver" +) + +var ( + version = "undefined" +) + +// getVersion returns a string representing the version information defined when +// the binary was built, or a sane default indicating a local build. a string is +// always returned. an error may be returned along with the string in the event +// that we detect a local build but are unable to get build metadata. +// +// TODO: support validation of the version (that it's a real version) +// TODO: support notifying the user if their version is out of date +func getVersion() (string, error) { + var arch string + var commit string + var modified bool + var platform string + + var v strings.Builder + + // this supports overriding the default version if the deprecated var used + // for setting the exact version for releases is supplied. we are doing this + // in order to give downstream package maintainers a longer window to + // migrate. + // + // TODO: 0.12.0: remove support for old build tags + if version == "undefined" && commands.GitExactTag != "" { + version = commands.GitExactTag + } + + // automatically add the v prefix if it's missing + if version != "undefined" && !strings.HasPrefix(version, "v") { + version = fmt.Sprintf("v%s", version) + } + + // reset the version string to undefined if it is invalid + if ok := semver.IsValid(version); !ok { + version = "undefined" + } + + v.WriteString(version) + + info, ok := debug.ReadBuildInfo() + if !ok { + v.WriteString(fmt.Sprintf(" (no build info)\n")) + return v.String(), errors.New("unable to read build metadata") + } + + for _, kv := range info.Settings { + switch kv.Key { + case "GOOS": + platform = kv.Value + case "GOARCH": + arch = kv.Value + case "vcs.modified": + if kv.Value == "true" { + modified = true + } + case "vcs.revision": + commit = kv.Value + } + } + + if commit != "" { + v.WriteString(fmt.Sprintf(" %.12s", commit)) + } + + if modified { + v.WriteString("/dirty") + } + + v.WriteString(fmt.Sprintf(" %s", info.GoVersion)) + + if platform != "" { + v.WriteString(fmt.Sprintf(" %s", platform)) + } + + if arch != "" { + v.WriteString(fmt.Sprintf(" %s", arch)) + } + + return fmt.Sprint(v.String(), "\n"), nil +} |