added git-browse-ci (#2536)

This commit is contained in:
Ralf Steube 2024-09-22 11:41:46 +02:00 committed by GitHub
parent 14541ada24
commit ede34025b4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 34 additions and 0 deletions

View File

@ -0,0 +1,27 @@
package cmd
import (
"github.com/carapace-sh/carapace"
"github.com/carapace-sh/carapace-bin/pkg/actions/tools/git"
"github.com/spf13/cobra"
)
var rootCmd = &cobra.Command{
Use: "git-browse-ci",
Short: "Opens the current git repository CI page in your default web browser",
Long: "https://github.com/tj/git-extras/blob/master/Commands.md#git-browse-ci",
Run: func(cmd *cobra.Command, args []string) {},
}
func Execute() error {
return rootCmd.Execute()
}
func init() {
carapace.Gen(rootCmd).Standalone()
rootCmd.Flags().Bool("help", false, "show help")
carapace.Gen(rootCmd).PositionalCompletion(
git.ActionRemotes(),
)
}

View File

@ -0,0 +1,7 @@
package main
import "github.com/carapace-sh/carapace-bin/completers/git-browse-ci_completer/cmd"
func main() {
cmd.Execute()
}