|
Flox Package Database 1
CRUD Operations on Nix Package Metadata
|
Minimal set of DB queries, largely focused on looking up info that is non-trivial to query with a "plain" SQLite statement. More...
#include <command.hh>
Public Member Functions | |
| command::VerboseParser & | getParser () |
| int | run () |
Execute the get routine. | |
Public Member Functions inherited from flox::pkgdb::PkgDbMixin< PkgDbReadOnly > | |
| void | openPkgDb () |
| Open a flox::pkgdb::PkgDb connection using the command state's dbPath or flake value. | |
| void | openPkgDb () |
| void | openPkgDb () |
| argparse::Argument & | addTargetArg (argparse::ArgumentParser &parser) |
Add target argument to any parser to read either a flake-ref or path to an existing database. | |
Public Member Functions inherited from flox::pkgdb::DbPathMixin | |
| argparse::Argument & | addDatabasePathOption (argparse::ArgumentParser &parser) |
Public Member Functions inherited from flox::command::InlineInputMixin | |
| argparse::Argument & | addSubtreeArg (argparse::ArgumentParser &parser) |
| argparse::Argument & | addFlakeRefArg (argparse::ArgumentParser &parser) |
| const RegistryInput & | getRegistryInput () |
| Return the parsed RegistryInput. | |
Public Member Functions inherited from flox::NixState | |
| NixState ()=default | |
Construct NixState using the systems default nix store. | |
| NixState (nix::ref< nix::Store > &store) | |
Construct NixState from an existing store connection. | |
| nix::ref< nix::EvalState > | getState () |
Lazily open a nix evaluator. | |
Public Member Functions inherited from flox::NixStoreMixin | |
| NixStoreMixin (const NixStoreMixin &)=default | |
| NixStoreMixin (NixStoreMixin &&)=default | |
| NixStoreMixin & | operator= (const NixStoreMixin &)=default |
| NixStoreMixin & | operator= (NixStoreMixin &&)=default |
| NixStoreMixin (const nix::ref< nix::Store > &store) | |
Construct NixStoreMixin from an existing store connection. | |
| NixStoreMixin () | |
Construct NixStoreMixin using the systems default nix store. | |
| nix::ref< nix::Store > | getStore () |
Lazily open a nix store connection. | |
Public Member Functions inherited from flox::command::AttrPathMixin | |
| argparse::Argument & | addAttrPathArgs (argparse::ArgumentParser &parser) |
| Sets the attribute path to be scraped. | |
| void | fixupAttrPath () |
Sets fallback attrPath to a package set. | |
Private Member Functions | |
| int | runId () |
Execute the get id routine. | |
| int | runDone () |
Execute the get done routine. | |
| int | runPath () |
Execute the get path routine. | |
| int | runFlake () |
Execute the get flake routine. | |
| int | runDb () |
Execute the get db routine. | |
| int | runPkg () |
Execute the get pkg routine. | |
Private Attributes | |
| command::VerboseParser | parser |
| command::VerboseParser | pId |
| command::VerboseParser | pPath |
| command::VerboseParser | pDone |
| command::VerboseParser | pFlake |
| command::VerboseParser | pDb |
| command::VerboseParser | pPkg |
| bool | isPkg = false |
| row_id | id = 0 |
Additional Inherited Members | |
Public Attributes inherited from flox::pkgdb::PkgDbMixin< PkgDbReadOnly > | |
| std::shared_ptr< FloxFlake > | flake |
| std::shared_ptr< T > | db |
Public Attributes inherited from flox::pkgdb::DbPathMixin | |
| std::optional< std::filesystem::path > | dbPath |
Public Attributes inherited from flox::command::AttrPathMixin | |
| flox::AttrPath | attrPath |
Protected Member Functions inherited from flox::command::InlineInputMixin | |
| void | parseFlakeRef (const std::string &flakeRef) |
| Fill registryInput by parsing a flake ref. | |
Minimal set of DB queries, largely focused on looking up info that is non-trivial to query with a "plain" SQLite statement.
This subcommand has additional subcommands:
pkgdb get id [--pkg] DB-PATH ATTR-PATH...(AttrSet|Packages).id for ATTR-PATH.pkgdb get done DB-PATH ATTR-PATH...AttrPath has been scraped.pkgdb get path [--pkg] DB-PATH IDAttrPath for (AttrSet|Packages).id.pkgdb get flake DB-PATHLockedFlake table including fingerprint, locked-ref, etc.pkgdb get db FLAKE-REF| int flox::pkgdb::GetCommand::run | ( | ) |
Execute the get routine.
EXIT_SUCCESS or EXIT_FAILURE.
|
private |
Execute the get db routine.
EXIT_SUCCESS or EXIT_FAILURE.
|
private |
Execute the get done routine.
EXIT_SUCCESS or EXIT_FAILURE.
|
private |
Execute the get flake routine.
EXIT_SUCCESS or EXIT_FAILURE.
|
private |
Execute the get id routine.
EXIT_SUCCESS or EXIT_FAILURE.
|
private |
Execute the get path routine.
EXIT_SUCCESS or EXIT_FAILURE.
|
private |
Execute the get pkg routine.
EXIT_SUCCESS or EXIT_FAILURE.
|
private |
get parser
|
private |
get db parser
|
private |
get done parser
|
private |
get flake parser
|
private |
get id parser
|
private |
get path parser
|
private |
get pkg parser