-
Notifications
You must be signed in to change notification settings - Fork 296
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ostree: Describe subcommands in help output #1267
Closed
peterbaouoft
wants to merge
6
commits into
ostreedev:master
from
peterbaouoft:describe_subcommands_in_help
Closed
Changes from 4 commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
beedb1f
ostree: Describe subcommands in help output
peterbaouoft 1ad2095
fixup! ostree: Describe subcommands in help output
peterbaouoft 808a446
ostree: move flags into command struct, pass down through builtins
peterbaouoft 0a7f95a
ostree: provide command description in a better place
peterbaouoft 8615c61
fixup! ostree: move flags into command struct, pass down through buil…
peterbaouoft 6c26e62
fixup! ostree: provide command description in a better place
peterbaouoft File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -32,37 +32,94 @@ | |
#include "ot-builtins.h" | ||
|
||
static OstreeCommand commands[] = { | ||
{ "admin", ostree_builtin_admin }, | ||
{ "cat", ostree_builtin_cat }, | ||
{ "checkout", ostree_builtin_checkout }, | ||
{ "checksum", ostree_builtin_checksum }, | ||
{ "commit", ostree_builtin_commit }, | ||
{ "config", ostree_builtin_config }, | ||
{ "diff", ostree_builtin_diff }, | ||
{ "export", ostree_builtin_export }, | ||
/* Note: all admin related commands have | ||
* no_repo as their command flag, but each | ||
* admin command may have their own | ||
* admin flag | ||
*/ | ||
{ "admin", OSTREE_BUILTIN_FLAG_NO_REPO, | ||
ostree_builtin_admin, | ||
"Commands that needs admin privilege" }, | ||
{ "cat", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_cat, | ||
"Concatenate contents of files"}, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Maybe Hum...perhaps we shouldn't be rewriting the descriptions in this commit. Nevermind, let's do that after. |
||
{ "checkout", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_checkout, | ||
"Check out a commit into a filesystem tree" }, | ||
{ "checksum", OSTREE_BUILTIN_FLAG_NO_REPO, | ||
ostree_builtin_checksum, | ||
"Checksum a file or directory" }, | ||
{ "commit", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_commit, | ||
"Commit a new revision" }, | ||
{ "config", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_config, | ||
"Change repo configuration settings" }, | ||
{ "diff", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_diff, | ||
"Compare directory TARGETDIR against revision REV"}, | ||
{ "export", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_export, | ||
"Stream COMMIT to stdout in tar format" }, | ||
#ifdef OSTREE_ENABLE_EXPERIMENTAL_API | ||
{ "find-remotes", ostree_builtin_find_remotes }, | ||
{ "create-usb", ostree_builtin_create_usb }, | ||
{ "find-remotes", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_find_remotes, | ||
"Find remotes to serve the given refs" }, | ||
{ "create-usb", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_create_usb, | ||
"Copy the refs to a USB stick" }, | ||
#endif | ||
{ "fsck", ostree_builtin_fsck }, | ||
{ "gpg-sign", ostree_builtin_gpg_sign }, | ||
{ "init", ostree_builtin_init }, | ||
{ "log", ostree_builtin_log }, | ||
{ "ls", ostree_builtin_ls }, | ||
{ "prune", ostree_builtin_prune }, | ||
{ "pull-local", ostree_builtin_pull_local }, | ||
{ "fsck", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_fsck, | ||
"Check the repository for consistency" }, | ||
{ "gpg-sign", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_gpg_sign, | ||
"Sign a commit" }, | ||
{ "init", OSTREE_BUILTIN_FLAG_NO_CHECK, | ||
ostree_builtin_init, | ||
"Initialize a new empty repository" }, | ||
{ "log", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_log, | ||
"Show log starting at commit or ref" }, | ||
{ "ls", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_ls, | ||
"List file paths" }, | ||
{ "prune", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_prune, | ||
"Search for unreachable objects" }, | ||
{ "pull-local", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_pull_local, | ||
"Copy data from SRC_REPO" }, | ||
#ifdef HAVE_LIBCURL_OR_LIBSOUP | ||
{ "pull", ostree_builtin_pull }, | ||
{ "pull", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_pull, | ||
"Download data from remote repository" }, | ||
#endif | ||
{ "refs", ostree_builtin_refs }, | ||
{ "remote", ostree_builtin_remote }, | ||
{ "reset", ostree_builtin_reset }, | ||
{ "rev-parse", ostree_builtin_rev_parse }, | ||
{ "show", ostree_builtin_show }, | ||
{ "static-delta", ostree_builtin_static_delta }, | ||
{ "summary", ostree_builtin_summary }, | ||
{ "refs", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_refs, | ||
"List refs" }, | ||
{ "remote", OSTREE_BUILTIN_FLAG_NO_REPO, | ||
ostree_builtin_remote, | ||
"Remote commands that may involve internet access" }, | ||
{ "reset", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_reset, | ||
"Reset a REF to a previous COMMIT" }, | ||
{ "rev-parse", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_rev_parse, | ||
"Output the target of a rev" }, | ||
{ "show", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_show, | ||
"Output a metadata object" }, | ||
{ "static-delta", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_static_delta, | ||
"Static delta related commands" }, | ||
{ "summary", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_summary, | ||
"Manage summary metadata" }, | ||
#if defined(HAVE_LIBSOUP) && defined(BUILDOPT_ENABLE_TRIVIAL_HTTPD_CMDLINE) | ||
{ "trivial-httpd", ostree_builtin_trivial_httpd }, | ||
{ "trivial-httpd", OSTREE_BUILTIN_FLAG_NONE, | ||
ostree_builtin_trivial_httpd, | ||
NULL }, | ||
#endif | ||
{ NULL } | ||
}; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd say
Commands for managing a host system booted with ostree
or so.