Documentation
¶
Overview ¶
Package product holds lockfile's names for lockkit, its refusal codes and its command exit codes.
Index ¶
Constants ¶
const ( ExitOK = 0 // answered, or done ExitError = 1 // no console running, or any other error ExitRefused = 2 // a refusal (E_* code, unknown_profile included) ExitDenied = 3 // denied by the human, or no answer in time ExitUsage = 64 // bad command line )
Exit codes of the commands. They depend on the outcome only, never on an answer (docs/security-model.md).
Variables ¶
var P = kit.Product{ Name: "lockfile", Tagline: "Your AI asks about the file. It never reads it.", Account: "lockfile", ClientsGroup: "lockfile-clients", KeychainService: "lockfile", EnvPrefix: "LOCKFILE_", Version: Version, }
P is lockfile for lockkit: account, clients group, directories, sockets.
var Version = "dev"
Version is the release version, set at build time with -ldflags "-X github.com/DavidGodefroid/lockfile/internal/product.Version=vX.Y.Z".
Functions ¶
func ApprovalRefusal ¶
ApprovalRefusal replaces lockkit's refusal of an approval with a fixed message: the outcome only (docs/security-model.md), never the human's typed reason, which lockkit already keeps in the audit.
func Code ¶
Code is the lockkit refusal code of c. It panics on a code that does not refuse a request: a bug, never a runtime condition.
Types ¶
This section is empty.