Artifact 4e9e732de00e03f418d37b79991dd4fc6518a01564a008879f9cdfe9388c4199:
- File
docs/site/content/docs/reference/sdk/cli/api.md
— part of check-in
[6273a0750d]
at
2026-07-22 23:03:24
on branch trunk
— fix: correct go.mod module path to go-libfossil (#76) (#117)
* fix: correct go.mod module path to go-libfossil (#76)
The module directive still declared github.com/danmestas/libfossil after the repository was renamed to go-libfossil. pkg.go.dev/godoc scraping matches the declared module path against its hosting path, so the stale path broke SDK doc generation.
Rename the module path across all four in-repo modules (root, the two db/driver submodules, observer/otel, and docs/site) and every internal import, plus the release workflow, the doc-generation script, and the docs.
No tag has been published under the go-libfossil path yet, so the cross-module requires cannot resolve from the proxy. Add replace directives pointing the in-repo requires at their local directories so GOWORK=off builds and the CI matrix resolve without a published version. These replaces are ignored by downstream consumers and can be dropped once new-path tags are cut.
* Guard releases against replace directives; regenerate SDK docs
The go-libfossil rename bridges the in-repo modules with `replace` directives. Go refuses a main module that carries them, so a tag cut while they are present breaks `go install .../cmd/libfossil@<tag>` and every `@version` fetch of the driver submodules. Add a Release workflow step that fails the job before anything is published if any tracked go.mod still contains a replace directive, so the bridge is a CI-enforced TODO rather than a silent landmine. The step comment records what unblocks a release: re-tag the submodules with the corrected module paths, bump the root requires, then drop the replace blocks.
Regenerate the SDK reference docs. The previous pass only substituted URLs over the pre-existing generated files, leaving stale signatures (Repo.Timeline was still documented as taking LogOpts rather than TimelineOpts). Note that gomarkdoc must be run outside a git worktree — inside one it silently strips every source link.
Also reword the README rename note, which read as though the import path had not changed, and re-sort the ncruces require block. (user: [email protected], size: 59888) [annotate] [blame] [check-ins using]
title: cli
<!-- Code generated by gomarkdoc. DO NOT EDIT -->cli
import "github.com/danmestas/go-libfossil/cli"
Index
- func Version() string
- type Globals
- type RepoAddCmd
- type RepoAnnotateCmd
- type RepoBisectBadCmd
- type RepoBisectCmd
- type RepoBisectGoodCmd
- type RepoBisectLsCmd
- type RepoBisectNextCmd
- type RepoBisectResetCmd
- type RepoBisectSkipCmd
- type RepoBisectStatusCmd
- type RepoBlameCmd
- type RepoBranchCloseCmd
- type RepoBranchCmd
- type RepoBranchLsCmd
- type RepoBranchNewCmd
- type RepoCatCmd
- type RepoCiCmd
- type RepoCloneCmd
- type RepoCmd
- type RepoCoCmd
- type RepoConfigCmd
- type RepoConfigGetCmd
- type RepoConfigLsCmd
- type RepoConfigSetCmd
- type RepoConflictsCmd
- type RepoConflictsExtractCmd
- type RepoConflictsLsCmd
- type RepoConflictsMergeCmd
- type RepoConflictsPickCmd
- type RepoConflictsShowCmd
- type RepoDeltaApplyCmd
- type RepoDeltaCmd
- type RepoDeltaCreateCmd
- type RepoDiffCmd
- type RepoExtractCmd
- type RepoHashCmd
- type RepoInfoCmd
- type RepoInviteCmd
- type RepoLsCmd
- type RepoMergeCmd
- type RepoMergeResolveCmd
- type RepoNewCmd
- type RepoOpenCmd
- type RepoQueryCmd
- type RepoRedoCmd
- type RepoRenameCmd
- type RepoResolveCmd
- type RepoRevertCmd
- type RepoRmCmd
- type RepoSchemaAddCmd
- type RepoSchemaCmd
- type RepoSchemaListCmd
- type RepoSchemaRemoveCmd
- type RepoSchemaShowCmd
- type RepoServeCmd
- type RepoStashApplyCmd
- type RepoStashClearCmd
- type RepoStashCmd
- type RepoStashDropCmd
- type RepoStashLsCmd
- type RepoStashPopCmd
- type RepoStashSaveCmd
- type RepoStatusCmd
- type RepoTagAddCmd
- type RepoTagCmd
- type RepoTagLsCmd
- type RepoTimelineCmd
- type RepoUVCmd
- type RepoUVDeleteCmd
- type RepoUVGetCmd
- type RepoUVLsCmd
- type RepoUVPutCmd
- type RepoUndoCmd
- type RepoUserCmd
- type RepoVerifyCmd
- type RepoWikiCmd
- type RepoWikiExportCmd
- type RepoWikiLsCmd
- type UserAddCmd
- type UserListCmd
- type UserPasswdCmd
- type UserRmCmd
- type UserUpdateCmd
- type VersionCmd
func Version
func Version() string
Version returns a single-line build identifier for this binary: the module version (or a build-time override), the Go toolchain version, and the platform. The shape is fixed at four whitespace-separated fields -- "libfossil <version> <go version> <os>/<arch>" -- regardless of which fields carried real data, so a caller can rely on strings.Fields(Version()) unconditionally. This is the same string both `libfossil version` and `libfossil --version` print.
type Globals
Globals holds flags shared by all CLI commands.
type Globals struct {
Repo string `short:"R" help:"Path to repository file" type:"path"`
Verbose bool `short:"v" help:"Verbose output"`
}
func (*Globals) OpenRepo
func (g *Globals) OpenRepo() (*libfossil.Repo, error)
OpenRepo opens a Fossil repository using the handle API. If Repo is empty, it searches for a .fossil file or .fslckout checkout.
type RepoAddCmd
RepoAddCmd stages files for addition in the checkout database.
type RepoAddCmd struct {
Files []string `arg:"" required:"" help:"Files to stage for addition"`
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoAddCmd) Run
func (c *RepoAddCmd) Run(g *Globals) error
type RepoAnnotateCmd
RepoAnnotateCmd annotates file lines with version history.
type RepoAnnotateCmd struct {
File string `arg:"" required:"" help:"File to annotate"`
Version string `help:"Starting version (default: tip)"`
}
func (*RepoAnnotateCmd) Run
func (c *RepoAnnotateCmd) Run(g *Globals) error
type RepoBisectBadCmd
RepoBisectBadCmd marks a version as bad.
type RepoBisectBadCmd struct {
Version string `arg:"" optional:"" help:"Version to mark (default: current checkout)"`
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoBisectBadCmd) Run
func (c *RepoBisectBadCmd) Run(g *Globals) error
type RepoBisectCmd
RepoBisectCmd groups binary search operations.
type RepoBisectCmd struct {
Good RepoBisectGoodCmd `cmd:"" help:"Mark version as good"`
Bad RepoBisectBadCmd `cmd:"" help:"Mark version as bad"`
Next RepoBisectNextCmd `cmd:"" help:"Check out midpoint version"`
Skip RepoBisectSkipCmd `cmd:"" help:"Skip current version"`
Reset RepoBisectResetCmd `cmd:"" help:"Clear bisect state"`
Ls RepoBisectLsCmd `cmd:"" help:"Show bisect path"`
Status RepoBisectStatusCmd `cmd:"" help:"Show bisect state"`
}
type RepoBisectGoodCmd
RepoBisectGoodCmd marks a version as good.
type RepoBisectGoodCmd struct {
Version string `arg:"" optional:"" help:"Version to mark (default: current checkout)"`
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoBisectGoodCmd) Run
func (c *RepoBisectGoodCmd) Run(g *Globals) error
type RepoBisectLsCmd
RepoBisectLsCmd shows the bisect path.
type RepoBisectLsCmd struct {
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoBisectLsCmd) Run
func (c *RepoBisectLsCmd) Run(g *Globals) error
type RepoBisectNextCmd
RepoBisectNextCmd checks out the bisect midpoint version.
type RepoBisectNextCmd struct {
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoBisectNextCmd) Run
func (c *RepoBisectNextCmd) Run(g *Globals) error
type RepoBisectResetCmd
RepoBisectResetCmd clears bisect state.
type RepoBisectResetCmd struct {
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoBisectResetCmd) Run
func (c *RepoBisectResetCmd) Run(g *Globals) error
type RepoBisectSkipCmd
RepoBisectSkipCmd skips the current version.
type RepoBisectSkipCmd struct {
Version string `arg:"" optional:"" help:"Version to skip (default: current checkout)"`
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoBisectSkipCmd) Run
func (c *RepoBisectSkipCmd) Run(g *Globals) error
type RepoBisectStatusCmd
RepoBisectStatusCmd shows bisect state.
type RepoBisectStatusCmd struct {
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoBisectStatusCmd) Run
func (c *RepoBisectStatusCmd) Run(g *Globals) error
type RepoBlameCmd
RepoBlameCmd is an alias for annotate.
type RepoBlameCmd struct {
RepoAnnotateCmd
}
type RepoBranchCloseCmd
RepoBranchCloseCmd closes a branch.
type RepoBranchCloseCmd struct {
Name string `arg:"" help:"Branch name to close"`
User string `help:"User for control artifacts (default: OS username)"`
}
func (*RepoBranchCloseCmd) Run
func (c *RepoBranchCloseCmd) Run(g *Globals) error
type RepoBranchCmd
RepoBranchCmd groups branch operations.
type RepoBranchCmd struct {
Ls RepoBranchLsCmd `cmd:"" help:"List branches"`
New RepoBranchNewCmd `cmd:"" help:"Create new branch"`
Close RepoBranchCloseCmd `cmd:"" help:"Close a branch"`
}
type RepoBranchLsCmd
RepoBranchLsCmd lists branches.
type RepoBranchLsCmd struct {
Closed bool `help:"Show only closed branches"`
All bool `help:"Show all branches (open and closed)"`
}
func (*RepoBranchLsCmd) Run
func (c *RepoBranchLsCmd) Run(g *Globals) error
type RepoBranchNewCmd
RepoBranchNewCmd creates a new branch.
type RepoBranchNewCmd struct {
Name string `arg:"" help:"Branch name"`
From string `help:"Parent version (default: tip)"`
Message string `short:"m" help:"Checkin comment"`
User string `help:"Checkin user (default: OS username)"`
}
func (*RepoBranchNewCmd) Run
func (c *RepoBranchNewCmd) Run(g *Globals) error
type RepoCatCmd
RepoCatCmd outputs the content of an artifact.
type RepoCatCmd struct {
Artifact string `arg:"" help:"Artifact UUID or prefix"`
Raw bool `help:"Output raw blob (no delta expansion)"`
}
func (*RepoCatCmd) Run
func (c *RepoCatCmd) Run(g *Globals) error
type RepoCiCmd
RepoCiCmd creates a new checkin (commit).
type RepoCiCmd struct {
Message string `short:"m" required:"" help:"Checkin comment"`
Files []string `arg:"" required:"" help:"Files to checkin"`
User string `help:"Checkin user (default: OS username)"`
Parent string `help:"Parent version UUID (default: tip)"`
Branch string `help:"Branch name for this checkin"`
}
func (*RepoCiCmd) Run
func (c *RepoCiCmd) Run(g *Globals) error
type RepoCloneCmd
RepoCloneCmd clones a remote Fossil repository.
type RepoCloneCmd struct {
URL string `arg:"" optional:"" help:"Remote Fossil server URL"`
Path string `arg:"" optional:"" help:"Local path for new repository file"`
User string `short:"u" help:"Username for clone auth"`
Pass string `short:"p" help:"Password for clone auth"`
Invite string `help:"Invite token (from fossil invite)"`
}
func (*RepoCloneCmd) Run
func (c *RepoCloneCmd) Run(g *Globals) error
type RepoCmd
RepoCmd is the top-level command group for repository operations. Embed this in your CLI struct alongside Globals for a complete fossil CLI.
type RepoCmd struct {
New RepoNewCmd `cmd:"" help:"Create a new repository"`
Clone RepoCloneCmd `cmd:"" help:"Clone a remote repository"`
Ci RepoCiCmd `cmd:"" help:"Checkin file changes"`
Co RepoCoCmd `cmd:"" help:"Checkout a version"`
Ls RepoLsCmd `cmd:"" help:"List files in a version"`
Timeline RepoTimelineCmd `cmd:"" help:"Show repository history"`
Cat RepoCatCmd `cmd:"" help:"Output artifact content"`
Info RepoInfoCmd `cmd:"" help:"Repository statistics"`
Hash RepoHashCmd `cmd:"" help:"Hash files (SHA1 or SHA3)"`
Delta RepoDeltaCmd `cmd:"" help:"Delta create/apply operations"`
Config RepoConfigCmd `cmd:"" help:"Repository configuration"`
Query RepoQueryCmd `cmd:"" help:"Execute SQL against repository"`
Verify RepoVerifyCmd `cmd:"" help:"Verify repository integrity"`
Resolve RepoResolveCmd `cmd:"" help:"Resolve symbolic name to UUID"`
Extract RepoExtractCmd `cmd:"" help:"Extract files from a version"`
Wiki RepoWikiCmd `cmd:"" help:"Wiki page operations"`
Tag RepoTagCmd `cmd:"" help:"Tag operations"`
Open RepoOpenCmd `cmd:"" help:"Open a checkout in a directory"`
Status RepoStatusCmd `cmd:"" help:"Show working directory changes"`
Add RepoAddCmd `cmd:"" help:"Stage files for addition"`
Rm RepoRmCmd `cmd:"" help:"Stage files for removal"`
Rename RepoRenameCmd `cmd:"" help:"Rename a tracked file"`
Revert RepoRevertCmd `cmd:"" help:"Undo staging changes"`
Diff RepoDiffCmd `cmd:"" help:"Show changes vs a version"`
Merge RepoMergeCmd `cmd:"" help:"Merge a divergent version"`
Conflicts RepoConflictsCmd `cmd:"" help:"List/manage unresolved conflicts"`
MarkResolved RepoMergeResolveCmd `cmd:"" name:"mark-resolved" help:"Mark a conflict as resolved"`
Undo RepoUndoCmd `cmd:"" help:"Undo last operation"`
Redo RepoRedoCmd `cmd:"" help:"Redo undone operation"`
Stash RepoStashCmd `cmd:"" help:"Stash working changes"`
Bisect RepoBisectCmd `cmd:"" help:"Binary search for bugs"`
Annotate RepoAnnotateCmd `cmd:"" help:"Annotate file lines with version history"`
Blame RepoBlameCmd `cmd:"" help:"Alias for annotate"`
Branch RepoBranchCmd `cmd:"" help:"Branch operations"`
UV RepoUVCmd `cmd:"" name:"uv" help:"Unversioned file operations"`
Schema RepoSchemaCmd `cmd:"" help:"Synced table schema operations"`
User RepoUserCmd `cmd:"" help:"User management"`
Invite RepoInviteCmd `cmd:"" help:"Generate invite token for a user"`
Serve RepoServeCmd `cmd:"" help:"Serve repository over HTTP for sync/clone"`
}
type RepoCoCmd
RepoCoCmd checks out a version to the working directory.
type RepoCoCmd struct {
Version string `arg:"" optional:"" help:"Version to checkout (default: tip)"`
Dir string `short:"d" help:"Output directory (default: current dir)" default:"."`
Force bool `help:"Overwrite existing files"`
}
func (*RepoCoCmd) Run
func (c *RepoCoCmd) Run(g *Globals) error
type RepoConfigCmd
RepoConfigCmd groups configuration operations.
type RepoConfigCmd struct {
Ls RepoConfigLsCmd `cmd:"" help:"List all config entries"`
Get RepoConfigGetCmd `cmd:"" help:"Get a config value"`
Set RepoConfigSetCmd `cmd:"" help:"Set a config value"`
}
type RepoConfigGetCmd
RepoConfigGetCmd gets a single config value.
type RepoConfigGetCmd struct {
Key string `arg:"" help:"Config key to get"`
}
func (*RepoConfigGetCmd) Run
func (c *RepoConfigGetCmd) Run(g *Globals) error
type RepoConfigLsCmd
RepoConfigLsCmd lists all config entries.
type RepoConfigLsCmd struct{}
func (*RepoConfigLsCmd) Run
func (c *RepoConfigLsCmd) Run(g *Globals) error
type RepoConfigSetCmd
RepoConfigSetCmd sets a config value.
type RepoConfigSetCmd struct {
Key string `arg:"" help:"Config key"`
Value string `arg:"" help:"Config value"`
}
func (*RepoConfigSetCmd) Run
func (c *RepoConfigSetCmd) Run(g *Globals) error
type RepoConflictsCmd
RepoConflictsCmd groups conflict management operations.
type RepoConflictsCmd struct {
Ls RepoConflictsLsCmd `cmd:"" default:"1" help:"List all conflicts"`
Show RepoConflictsShowCmd `cmd:"" help:"Show all versions of a conflicted file"`
Pick RepoConflictsPickCmd `cmd:"" help:"Resolve by picking one version"`
Merge RepoConflictsMergeCmd `cmd:"" help:"Resolve by re-merging with a different strategy"`
Extract RepoConflictsExtractCmd `cmd:"" help:"Extract all versions to disk for manual editing"`
Dir string `short:"d" help:"Checkout directory" default:"."`
}
type RepoConflictsExtractCmd
RepoConflictsExtractCmd extracts all versions to disk for manual editing.
type RepoConflictsExtractCmd struct {
File string `arg:"" help:"Conflicted file to extract"`
Dir string `short:"d" help:"Output directory" default:"."`
}
func (*RepoConflictsExtractCmd) Run
func (c *RepoConflictsExtractCmd) Run(g *Globals) error
type RepoConflictsLsCmd
RepoConflictsLsCmd lists all conflicts.
type RepoConflictsLsCmd struct{}
func (*RepoConflictsLsCmd) Run
func (c *RepoConflictsLsCmd) Run(g *Globals) error
type RepoConflictsMergeCmd
RepoConflictsMergeCmd resolves a conflict by re-merging with a specified strategy.
type RepoConflictsMergeCmd struct {
File string `arg:"" help:"Conflicted file to re-merge"`
Strategy string `help:"Strategy to use" default:"three-way"`
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoConflictsMergeCmd) Run
func (c *RepoConflictsMergeCmd) Run(g *Globals) error
type RepoConflictsPickCmd
RepoConflictsPickCmd resolves a conflict by picking one version.
type RepoConflictsPickCmd struct {
File string `arg:"" help:"Conflicted file to resolve"`
Local bool `help:"Keep local version" xor:"version"`
Remote bool `help:"Keep remote version" xor:"version"`
Base bool `help:"Revert to base version" xor:"version"`
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoConflictsPickCmd) Run
func (c *RepoConflictsPickCmd) Run(g *Globals) error
type RepoConflictsShowCmd
RepoConflictsShowCmd shows all versions of a conflicted file.
type RepoConflictsShowCmd struct {
File string `arg:"" help:"Conflicted file to show"`
}
func (*RepoConflictsShowCmd) Run
func (c *RepoConflictsShowCmd) Run(g *Globals) error
type RepoDeltaApplyCmd
RepoDeltaApplyCmd applies a delta to a source file.
type RepoDeltaApplyCmd struct {
Source string `arg:"" help:"Source (original) file"`
Delta string `arg:"" help:"Delta file"`
Output string `short:"o" help:"Output file (default: stdout)"`
}
func (*RepoDeltaApplyCmd) Run
func (c *RepoDeltaApplyCmd) Run(g *Globals) error
type RepoDeltaCmd
RepoDeltaCmd groups delta create/apply operations.
type RepoDeltaCmd struct {
Create RepoDeltaCreateCmd `cmd:"" help:"Create a delta between two files"`
Apply RepoDeltaApplyCmd `cmd:"" help:"Apply a delta to a source file"`
}
type RepoDeltaCreateCmd
RepoDeltaCreateCmd creates a delta between two files.
type RepoDeltaCreateCmd struct {
Source string `arg:"" help:"Source (original) file"`
Target string `arg:"" help:"Target (new) file"`
Output string `short:"o" help:"Output file (default: stdout)"`
}
func (*RepoDeltaCreateCmd) Run
func (c *RepoDeltaCreateCmd) Run(g *Globals) error
type RepoDiffCmd
RepoDiffCmd shows changes in the working directory vs a repository version.
type RepoDiffCmd struct {
Version string `arg:"" optional:"" help:"Version to diff against (default: tip)"`
Dir string `short:"d" help:"Working directory to compare" default:"."`
Unified int `short:"U" help:"Lines of context" default:"3"`
}
func (*RepoDiffCmd) Run
func (c *RepoDiffCmd) Run(g *Globals) error
type RepoExtractCmd
RepoExtractCmd extracts files from a version.
type RepoExtractCmd struct {
Version string `help:"Version to extract from (default: tip)"`
Files []string `arg:"" optional:"" help:"Files to extract (default: all)"`
Dir string `short:"d" help:"Output directory" default:"."`
}
func (*RepoExtractCmd) Run
func (c *RepoExtractCmd) Run(g *Globals) error
type RepoHashCmd
RepoHashCmd hashes files using SHA1 or SHA3-256.
type RepoHashCmd struct {
Files []string `arg:"" required:"" help:"Files to hash"`
SHA3 bool `name:"sha3" help:"Use SHA3-256 instead of SHA1"`
}
func (*RepoHashCmd) Run
func (c *RepoHashCmd) Run(g *Globals) error
type RepoInfoCmd
RepoInfoCmd shows repository statistics.
type RepoInfoCmd struct{}
func (*RepoInfoCmd) Run
func (c *RepoInfoCmd) Run(g *Globals) error
type RepoInviteCmd
RepoInviteCmd generates an invite token for a new user.
type RepoInviteCmd struct {
Login string `arg:"" help:"Username for the invitee"`
Cap string `help:"Capability string (e.g. oi)" required:""`
URL string `help:"Sync URL to embed in token" default:""`
TTL time.Duration `help:"Token time-to-live (e.g. 24h)" default:"0"`
}
func (*RepoInviteCmd) Run
func (c *RepoInviteCmd) Run(g *Globals) error
type RepoLsCmd
RepoLsCmd lists files in a version.
type RepoLsCmd struct {
Version string `arg:"" optional:"" help:"Version to list (default: tip)"`
Long bool `short:"l" help:"Show sizes and hashes"`
}
func (*RepoLsCmd) Run
func (c *RepoLsCmd) Run(g *Globals) error
type RepoMergeCmd
RepoMergeCmd merges a divergent version into the current checkout.
type RepoMergeCmd struct {
Version string `arg:"" help:"Version to merge into current checkout"`
Strategy string `help:"Override merge strategy for all files"`
DryRun bool `help:"Show what would be merged without writing"`
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoMergeCmd) Run
func (c *RepoMergeCmd) Run(g *Globals) error
type RepoMergeResolveCmd
RepoMergeResolveCmd marks a file conflict as resolved.
type RepoMergeResolveCmd struct {
File string `arg:"" help:"File to mark as resolved"`
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoMergeResolveCmd) Run
func (c *RepoMergeResolveCmd) Run(g *Globals) error
type RepoNewCmd
RepoNewCmd creates a new Fossil repository.
type RepoNewCmd struct {
Path string `arg:"" help:"Path for new repository file"`
User string `help:"Default user name" default:""`
}
func (*RepoNewCmd) Run
func (c *RepoNewCmd) Run(g *Globals) error
type RepoOpenCmd
RepoOpenCmd opens a checkout in a directory, creating the .fslckout database.
type RepoOpenCmd struct {
Dir string `arg:"" optional:"" help:"Checkout directory (default: current dir)" default:"."`
}
func (*RepoOpenCmd) Run
func (c *RepoOpenCmd) Run(g *Globals) error
type RepoQueryCmd
RepoQueryCmd executes raw SQL against the repository database.
type RepoQueryCmd struct {
SQL string `arg:"" help:"SQL query to execute"`
}
func (*RepoQueryCmd) Run
func (c *RepoQueryCmd) Run(g *Globals) error
type RepoRedoCmd
RepoRedoCmd re-applies the last undone operation.
type RepoRedoCmd struct {
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoRedoCmd) Run
func (c *RepoRedoCmd) Run(g *Globals) error
type RepoRenameCmd
RepoRenameCmd renames a tracked file in the checkout.
type RepoRenameCmd struct {
From string `arg:"" help:"Current file name"`
To string `arg:"" help:"New file name"`
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoRenameCmd) Run
func (c *RepoRenameCmd) Run(g *Globals) error
type RepoResolveCmd
RepoResolveCmd resolves a symbolic name to UUID and RID.
type RepoResolveCmd struct {
Name string `arg:"" help:"Symbolic name, UUID, or prefix to resolve (e.g. trunk, tip, UUID prefix)"`
}
func (*RepoResolveCmd) Run
func (c *RepoResolveCmd) Run(g *Globals) error
type RepoRevertCmd
RepoRevertCmd undoes staging changes in the checkout.
type RepoRevertCmd struct {
Files []string `arg:"" optional:"" help:"Files to revert (default: all)"`
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoRevertCmd) Run
func (c *RepoRevertCmd) Run(g *Globals) error
type RepoRmCmd
RepoRmCmd stages files for removal from the checkout.
type RepoRmCmd struct {
Files []string `arg:"" required:"" help:"Files to stage for removal"`
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoRmCmd) Run
func (c *RepoRmCmd) Run(g *Globals) error
type RepoSchemaAddCmd
RepoSchemaAddCmd registers a new synced table.
type RepoSchemaAddCmd struct {
Name string `arg:"" help:"Table name (without x_ prefix)"`
Columns string `required:"" help:"Column defs: name:type[:pk],... (e.g. peer_id:text:pk,addr:text)"`
Conflict string `default:"mtime-wins" enum:"self-write,mtime-wins,owner-write" help:"Conflict strategy"`
}
func (*RepoSchemaAddCmd) Run
func (c *RepoSchemaAddCmd) Run(g *Globals) error
type RepoSchemaCmd
RepoSchemaCmd groups synced table schema operations.
type RepoSchemaCmd struct {
Add RepoSchemaAddCmd `cmd:"" help:"Register a new synced table"`
List RepoSchemaListCmd `cmd:"" help:"List registered synced tables"`
Show RepoSchemaShowCmd `cmd:"" help:"Show table schema details"`
Remove RepoSchemaRemoveCmd `cmd:"" help:"Remove a synced table registration"`
}
type RepoSchemaListCmd
RepoSchemaListCmd lists registered synced tables.
type RepoSchemaListCmd struct{}
func (*RepoSchemaListCmd) Run
func (c *RepoSchemaListCmd) Run(g *Globals) error
type RepoSchemaRemoveCmd
RepoSchemaRemoveCmd removes a synced table registration.
type RepoSchemaRemoveCmd struct {
Name string `arg:"" help:"Table name (without x_ prefix)"`
}
func (*RepoSchemaRemoveCmd) Run
func (c *RepoSchemaRemoveCmd) Run(g *Globals) error
type RepoSchemaShowCmd
RepoSchemaShowCmd shows table schema details.
type RepoSchemaShowCmd struct {
Name string `arg:"" help:"Table name (without x_ prefix)"`
}
func (*RepoSchemaShowCmd) Run
func (c *RepoSchemaShowCmd) Run(g *Globals) error
type RepoServeCmd
RepoServeCmd starts an HTTP xfer server for the repository so a remote fossil client -- the canonical binary or another instance of this tool -- can clone or sync against it. This is a thin wrapper: all serving logic lives in Repo.ServeHTTP; the command's job is to open the repo, resolve the bind address, and translate process interrupt into the context cancellation that ServeHTTP already honors.
type RepoServeCmd struct {
Addr string `short:"P" default:"127.0.0.1:8080" help:"Bind address as host:port"`
}
func (*RepoServeCmd) Run
func (c *RepoServeCmd) Run(g *Globals) error
type RepoStashApplyCmd
RepoStashApplyCmd applies a stash entry without removing it.
type RepoStashApplyCmd struct {
ID int64 `arg:"" optional:"" help:"Stash ID to apply (default: latest)"`
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoStashApplyCmd) Run
func (c *RepoStashApplyCmd) Run(g *Globals) error
type RepoStashClearCmd
RepoStashClearCmd removes all stash entries.
type RepoStashClearCmd struct{}
func (*RepoStashClearCmd) Run
func (c *RepoStashClearCmd) Run(g *Globals) error
type RepoStashCmd
RepoStashCmd groups stash operations.
type RepoStashCmd struct {
Save RepoStashSaveCmd `cmd:"" help:"Stash working changes"`
Pop RepoStashPopCmd `cmd:"" help:"Apply top stash and drop it"`
Apply RepoStashApplyCmd `cmd:"" help:"Apply stash without dropping"`
Ls RepoStashLsCmd `cmd:"" help:"List stash entries"`
Drop RepoStashDropCmd `cmd:"" help:"Remove stash entry"`
Clear RepoStashClearCmd `cmd:"" help:"Remove all stash entries"`
}
type RepoStashDropCmd
RepoStashDropCmd removes a stash entry by ID.
type RepoStashDropCmd struct {
ID int64 `arg:"" required:"" help:"Stash ID to drop"`
}
func (*RepoStashDropCmd) Run
func (c *RepoStashDropCmd) Run(g *Globals) error
type RepoStashLsCmd
RepoStashLsCmd lists stash entries.
type RepoStashLsCmd struct{}
func (*RepoStashLsCmd) Run
func (c *RepoStashLsCmd) Run(g *Globals) error
type RepoStashPopCmd
RepoStashPopCmd pops the top stash entry.
type RepoStashPopCmd struct {
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoStashPopCmd) Run
func (c *RepoStashPopCmd) Run(g *Globals) error
type RepoStashSaveCmd
RepoStashSaveCmd saves working changes to the stash.
type RepoStashSaveCmd struct {
Message string `short:"m" help:"Stash message" default:""`
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoStashSaveCmd) Run
func (c *RepoStashSaveCmd) Run(g *Globals) error
type RepoStatusCmd
RepoStatusCmd shows working directory changes vs the tip version.
type RepoStatusCmd struct {
Dir string `short:"d" help:"Checkout directory to scan" default:"."`
}
func (*RepoStatusCmd) Run
func (c *RepoStatusCmd) Run(g *Globals) error
type RepoTagAddCmd
RepoTagAddCmd adds a tag to an artifact.
type RepoTagAddCmd struct {
Tag string `arg:"" help:"Tag name"`
Value string `arg:"" optional:"" help:"Tag value (optional)"`
Version string `help:"Version to tag (default: tip)"`
}
func (*RepoTagAddCmd) Run
func (c *RepoTagAddCmd) Run(g *Globals) error
type RepoTagCmd
RepoTagCmd groups tag operations.
type RepoTagCmd struct {
Ls RepoTagLsCmd `cmd:"" help:"List tags on an artifact"`
Add RepoTagAddCmd `cmd:"" help:"Add a tag to an artifact"`
}
type RepoTagLsCmd
RepoTagLsCmd lists tags on an artifact.
type RepoTagLsCmd struct {
Version string `arg:"" optional:"" help:"Version to list tags for (default: tip)"`
}
func (*RepoTagLsCmd) Run
func (c *RepoTagLsCmd) Run(g *Globals) error
type RepoTimelineCmd
RepoTimelineCmd shows repository timeline/history.
type RepoTimelineCmd struct {
Limit int `short:"n" default:"20" help:"Number of entries"`
}
func (*RepoTimelineCmd) Run
func (c *RepoTimelineCmd) Run(g *Globals) error
type RepoUVCmd
RepoUVCmd groups unversioned file operations.
type RepoUVCmd struct {
Ls RepoUVLsCmd `cmd:"" help:"List unversioned files"`
Put RepoUVPutCmd `cmd:"" help:"Add or update an unversioned file"`
Get RepoUVGetCmd `cmd:"" help:"Retrieve an unversioned file"`
Delete RepoUVDeleteCmd `cmd:"" help:"Delete an unversioned file (creates tombstone)"`
}
type RepoUVDeleteCmd
RepoUVDeleteCmd deletes an unversioned file (creates a tombstone).
type RepoUVDeleteCmd struct {
Name string `arg:"" help:"Name of the unversioned file to delete"`
}
func (*RepoUVDeleteCmd) Run
func (c *RepoUVDeleteCmd) Run(g *Globals) error
type RepoUVGetCmd
RepoUVGetCmd retrieves an unversioned file.
type RepoUVGetCmd struct {
Name string `arg:"" help:"Name of the unversioned file"`
Output string `short:"o" help:"Output file (default: stdout)"`
}
func (*RepoUVGetCmd) Run
func (c *RepoUVGetCmd) Run(g *Globals) error
type RepoUVLsCmd
RepoUVLsCmd lists unversioned files.
type RepoUVLsCmd struct{}
func (*RepoUVLsCmd) Run
func (c *RepoUVLsCmd) Run(g *Globals) error
type RepoUVPutCmd
RepoUVPutCmd adds or updates an unversioned file.
type RepoUVPutCmd struct {
Name string `arg:"" help:"Name of the unversioned file"`
File string `arg:"" help:"Local file to upload"`
}
func (*RepoUVPutCmd) Run
func (c *RepoUVPutCmd) Run(g *Globals) error
type RepoUndoCmd
RepoUndoCmd undoes the last checkout operation.
type RepoUndoCmd struct {
Dir string `short:"d" help:"Checkout directory" default:"."`
}
func (*RepoUndoCmd) Run
func (c *RepoUndoCmd) Run(g *Globals) error
type RepoUserCmd
RepoUserCmd groups user management operations.
type RepoUserCmd struct {
Add UserAddCmd `cmd:"" help:"Create a new user"`
List UserListCmd `cmd:"" help:"List all users"`
Update UserUpdateCmd `cmd:"" help:"Update user capabilities"`
Rm UserRmCmd `cmd:"" help:"Delete a user"`
Passwd UserPasswdCmd `cmd:"" help:"Reset user password"`
}
type RepoVerifyCmd
RepoVerifyCmd verifies repository integrity.
type RepoVerifyCmd struct{}
func (*RepoVerifyCmd) Run
func (c *RepoVerifyCmd) Run(g *Globals) error
type RepoWikiCmd
RepoWikiCmd groups wiki operations.
type RepoWikiCmd struct {
Ls RepoWikiLsCmd `cmd:"" help:"List wiki pages"`
Export RepoWikiExportCmd `cmd:"" help:"Export a wiki page"`
}
type RepoWikiExportCmd
RepoWikiExportCmd exports a wiki page.
type RepoWikiExportCmd struct {
Page string `arg:"" help:"Wiki page name or artifact UUID"`
Output string `short:"o" help:"Output file (default: stdout)"`
}
func (*RepoWikiExportCmd) Run
func (c *RepoWikiExportCmd) Run(g *Globals) error
type RepoWikiLsCmd
RepoWikiLsCmd lists wiki pages.
type RepoWikiLsCmd struct{}
func (*RepoWikiLsCmd) Run
func (c *RepoWikiLsCmd) Run(g *Globals) error
type UserAddCmd
UserAddCmd creates a new user.
type UserAddCmd struct {
Login string `arg:"" help:"Username"`
Cap string `help:"Capability string (e.g. oi)" required:""`
}
func (*UserAddCmd) Run
func (c *UserAddCmd) Run(g *Globals) error
type UserListCmd
UserListCmd lists all users.
type UserListCmd struct{}
func (*UserListCmd) Run
func (c *UserListCmd) Run(g *Globals) error
type UserPasswdCmd
UserPasswdCmd resets a user's password.
type UserPasswdCmd struct {
Login string `arg:"" help:"Username"`
}
func (*UserPasswdCmd) Run
func (c *UserPasswdCmd) Run(g *Globals) error
type UserRmCmd
UserRmCmd deletes a user.
type UserRmCmd struct {
Login string `arg:"" help:"Username"`
}
func (*UserRmCmd) Run
func (c *UserRmCmd) Run(g *Globals) error
type UserUpdateCmd
UserUpdateCmd updates user capabilities.
type UserUpdateCmd struct {
Login string `arg:"" help:"Username"`
Cap string `help:"New capability string" required:""`
}
func (*UserUpdateCmd) Run
func (c *UserUpdateCmd) Run(g *Globals) error
type VersionCmd
VersionCmd prints a single-line, stable, machine-parseable build identifier and exits 0.
type VersionCmd struct{}
func (*VersionCmd) Run
func (c *VersionCmd) Run() error
Run prints Version() and always succeeds: there is nothing about the local environment that can make reporting the build identifier fail.
Generated by gomarkdoc