importcmd

package
v0.4.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 4, 2026 License: MIT Imports: 9 Imported by: 0

Documentation

Overview

Package importcmd provides the "import" parent command, which groups subcommands for importing issues from structured file formats (currently JSONL). The parent command has no action of its own — it exists only to namespace the import subcommands.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func JSONLRun

func JSONLRun(ctx context.Context, input JSONLRunInput) error

JSONLRun executes the JSONL import pipeline: parse the input, validate all lines against the database prefix, then import the validated records as issues. Validation errors are reported without creating any issues; import errors are reported per-line after partial completion.

func NewCmd

func NewCmd(f *cmdutil.Factory) *cli.Command

NewCmd constructs the "import" parent command, which groups subcommands for importing issues from various file formats. The parent command has no action of its own — it exists only to namespace the import subcommands.

Types

type JSONLRunInput

type JSONLRunInput struct {
	Service     driving.Service
	Reader      io.Reader
	FilePath    string
	Author      string
	ForceAuthor bool
	JSON        bool
	WriteTo     io.Writer
	ErrWriteTo  io.Writer
	ColorScheme func() *iostreams.ColorScheme
}

JSONLRunInput holds the parameters for the jsonl subcommand's core logic, decoupled from CLI flag parsing so it can be tested directly. The command reads a JSONL file, validates all lines, then imports them as issues.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL