Skip to content

Commit

Permalink
added jj
Browse files Browse the repository at this point in the history
  • Loading branch information
rsteube committed Nov 2, 2023
1 parent 50ed2f9 commit 5ad2644
Show file tree
Hide file tree
Showing 204 changed files with 3,893 additions and 0 deletions.
20 changes: 20 additions & 0 deletions completers/jj_completer/cmd/abandon.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var abandonCmd = &cobra.Command{
Use: "abandon",
Short: "Abandon a revision",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(abandonCmd).Standalone()

abandonCmd.Flags().BoolP("help", "h", false, "Print help (see more with '--help')")
abandonCmd.Flags().BoolP("summary", "s", false, "Do not print every abandoned commit on a separate line")
rootCmd.AddCommand(abandonCmd)
}
21 changes: 21 additions & 0 deletions completers/jj_completer/cmd/backout.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var backoutCmd = &cobra.Command{
Use: "backout",
Short: "Apply the reverse of a revision on top of another revision",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(backoutCmd).Standalone()

backoutCmd.Flags().StringSliceP("destination", "d", []string{}, "The revision to apply the reverse changes on top of")
backoutCmd.Flags().BoolP("help", "h", false, "Print help (see more with '--help')")
backoutCmd.Flags().StringP("revision", "r", "", "The revision to apply the reverse of")
rootCmd.AddCommand(backoutCmd)
}
19 changes: 19 additions & 0 deletions completers/jj_completer/cmd/branch.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var branchCmd = &cobra.Command{
Use: "branch",
Short: "Manage branches",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(branchCmd).Standalone()

branchCmd.Flags().BoolP("help", "h", false, "Print help (see more with '--help')")
rootCmd.AddCommand(branchCmd)
}
21 changes: 21 additions & 0 deletions completers/jj_completer/cmd/branch_create.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var branch_createCmd = &cobra.Command{
Use: "create",
Short: "Create a new branch",
Aliases: []string{"c"},
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(branch_createCmd).Standalone()

branch_createCmd.Flags().BoolP("help", "h", false, "Print help (see more with '--help')")
branch_createCmd.Flags().StringP("revision", "r", "", "The branch's target revision")
branchCmd.AddCommand(branch_createCmd)
}
20 changes: 20 additions & 0 deletions completers/jj_completer/cmd/branch_delete.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var branch_deleteCmd = &cobra.Command{
Use: "delete",
Short: "Delete an existing branch and propagate the deletion to remotes on the next push",
Aliases: []string{"d"},
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(branch_deleteCmd).Standalone()

branch_deleteCmd.Flags().BoolP("help", "h", false, "Print help (see more with '--help')")
branchCmd.AddCommand(branch_deleteCmd)
}
20 changes: 20 additions & 0 deletions completers/jj_completer/cmd/branch_forget.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var branch_forgetCmd = &cobra.Command{
Use: "forget",
Short: "Forget everything about a branch, including its local and remote targets",
Aliases: []string{"f"},
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(branch_forgetCmd).Standalone()

branch_forgetCmd.Flags().BoolP("help", "h", false, "Print help (see more with '--help')")
branchCmd.AddCommand(branch_forgetCmd)
}
18 changes: 18 additions & 0 deletions completers/jj_completer/cmd/branch_help.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var branch_helpCmd = &cobra.Command{
Use: "help",
Short: "Print this message or the help of the given subcommand(s)",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(branch_helpCmd).Standalone()

branchCmd.AddCommand(branch_helpCmd)
}
18 changes: 18 additions & 0 deletions completers/jj_completer/cmd/branch_help_create.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var branch_help_createCmd = &cobra.Command{
Use: "create",
Short: "Create a new branch",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(branch_help_createCmd).Standalone()

branch_helpCmd.AddCommand(branch_help_createCmd)
}
18 changes: 18 additions & 0 deletions completers/jj_completer/cmd/branch_help_delete.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var branch_help_deleteCmd = &cobra.Command{
Use: "delete",
Short: "Delete an existing branch and propagate the deletion to remotes on the next push",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(branch_help_deleteCmd).Standalone()

branch_helpCmd.AddCommand(branch_help_deleteCmd)
}
18 changes: 18 additions & 0 deletions completers/jj_completer/cmd/branch_help_forget.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var branch_help_forgetCmd = &cobra.Command{
Use: "forget",
Short: "Forget everything about a branch, including its local and remote targets",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(branch_help_forgetCmd).Standalone()

branch_helpCmd.AddCommand(branch_help_forgetCmd)
}
18 changes: 18 additions & 0 deletions completers/jj_completer/cmd/branch_help_help.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var branch_help_helpCmd = &cobra.Command{
Use: "help",
Short: "Print this message or the help of the given subcommand(s)",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(branch_help_helpCmd).Standalone()

branch_helpCmd.AddCommand(branch_help_helpCmd)
}
18 changes: 18 additions & 0 deletions completers/jj_completer/cmd/branch_help_list.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var branch_help_listCmd = &cobra.Command{
Use: "list",
Short: "List branches and their targets",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(branch_help_listCmd).Standalone()

branch_helpCmd.AddCommand(branch_help_listCmd)
}
18 changes: 18 additions & 0 deletions completers/jj_completer/cmd/branch_help_set.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var branch_help_setCmd = &cobra.Command{
Use: "set",
Short: "Update a given branch to point to a certain commit",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(branch_help_setCmd).Standalone()

branch_helpCmd.AddCommand(branch_help_setCmd)
}
18 changes: 18 additions & 0 deletions completers/jj_completer/cmd/branch_help_track.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var branch_help_trackCmd = &cobra.Command{
Use: "track",
Short: "Start tracking given remote branches",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(branch_help_trackCmd).Standalone()

branch_helpCmd.AddCommand(branch_help_trackCmd)
}
18 changes: 18 additions & 0 deletions completers/jj_completer/cmd/branch_help_untrack.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var branch_help_untrackCmd = &cobra.Command{
Use: "untrack",
Short: "Stop tracking given remote branches",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(branch_help_untrackCmd).Standalone()

branch_helpCmd.AddCommand(branch_help_untrackCmd)
}
22 changes: 22 additions & 0 deletions completers/jj_completer/cmd/branch_list.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var branch_listCmd = &cobra.Command{
Use: "list",
Short: "List branches and their targets",
Aliases: []string{"l"},
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(branch_listCmd).Standalone()

branch_listCmd.Flags().BoolP("all", "a", false, "Show all tracking and non-tracking remote branches including the ones whose targets are synchronized with the local branches")
branch_listCmd.Flags().BoolP("help", "h", false, "Print help (see more with '--help')")
branch_listCmd.Flags().StringSliceP("revisions", "r", []string{}, "Show branches whose local targets are in the given revisions")
branchCmd.AddCommand(branch_listCmd)
}
22 changes: 22 additions & 0 deletions completers/jj_completer/cmd/branch_set.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var branch_setCmd = &cobra.Command{
Use: "set",
Short: "Update a given branch to point to a certain commit",
Aliases: []string{"s"},
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(branch_setCmd).Standalone()

branch_setCmd.Flags().BoolP("allow-backwards", "B", false, "Allow moving the branch backwards or sideways")
branch_setCmd.Flags().BoolP("help", "h", false, "Print help (see more with '--help')")
branch_setCmd.Flags().StringP("revision", "r", "", "The branch's target revision")
branchCmd.AddCommand(branch_setCmd)
}
19 changes: 19 additions & 0 deletions completers/jj_completer/cmd/branch_track.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var branch_trackCmd = &cobra.Command{
Use: "track",
Short: "Start tracking given remote branches",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(branch_trackCmd).Standalone()

branch_trackCmd.Flags().BoolP("help", "h", false, "Print help (see more with '--help')")
branchCmd.AddCommand(branch_trackCmd)
}
19 changes: 19 additions & 0 deletions completers/jj_completer/cmd/branch_untrack.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
package cmd

import (
"github.com/rsteube/carapace"
"github.com/spf13/cobra"
)

var branch_untrackCmd = &cobra.Command{
Use: "untrack",
Short: "Stop tracking given remote branches",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(branch_untrackCmd).Standalone()

branch_untrackCmd.Flags().BoolP("help", "h", false, "Print help (see more with '--help')")
branchCmd.AddCommand(branch_untrackCmd)
}
Loading

0 comments on commit 5ad2644

Please sign in to comment.