-
Notifications
You must be signed in to change notification settings - Fork 3
Format detailed help using markdown and auto-generate reference docs #14
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
Open
adamwg
wants to merge
2
commits into
crossplane:main
Choose a base branch
from
adamwg:awg/docsdocsdocs
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+2,103
−426
Open
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
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 hidden or 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 hidden or 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 |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| The `config` command manages the configuration file for the `crossplane` | ||
| CLI. The config file location is, in priority order: | ||
|
|
||
| 1. The `--config` flag. | ||
| 2. The `CROSSPLANE_CONFIG` environment variable. | ||
| 3. `$XDG_CONFIG_HOME/crossplane/config.yaml` (or `~/.config/crossplane/config.yaml`). | ||
|
|
||
| ## Examples | ||
|
|
||
| Show the current effective config: | ||
|
|
||
| ```shell | ||
| crossplane config view | ||
| ``` | ||
|
|
||
| Enable alpha commands: | ||
|
|
||
| ```shell | ||
| crossplane config set features.enableAlpha true | ||
| ``` |
This file contains hidden or 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
31 changes: 31 additions & 0 deletions
31
cmd/crossplane/convert/compositionenvironment/help/composition-environment.md
This file contains hidden or 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 |
|---|---|---|
| @@ -0,0 +1,31 @@ | ||
| The `composition convert composition-environment` command converts a Crossplane | ||
| Composition to use `function-environment-configs` in place of native Composition | ||
| Environments, which were removed in Crossplane v1.18. | ||
|
|
||
| It adds a function pipeline step using | ||
| `crossplane-contrib/function-environment-configs` if needed. By default the | ||
| function is referenced as `function-environment-configs`, but this can be | ||
| overridden with `--function-environment-configs-ref`. | ||
|
|
||
| ## Examples | ||
|
|
||
| Convert an existing pipeline mode Composition using native Composition | ||
| Environment to `function-environment-configs`: | ||
|
|
||
| ```shell | ||
| crossplane composition convert composition-environment composition.yaml \ | ||
| -o composition-environment.yaml | ||
|
adamwg marked this conversation as resolved.
|
||
| ``` | ||
|
|
||
| Use a different functionRef and output to stdout: | ||
|
|
||
| ```shell | ||
| crossplane composition convert composition-environment composition.yaml \ | ||
| --function-environment-configs-ref=local-function-environment-configs | ||
| ``` | ||
|
|
||
| Read a composition from stdin and output the updated composition on stdout: | ||
|
|
||
| ```shell | ||
| cat composition.yaml | crossplane composition convert composition-environment | ||
| ``` | ||
This file contains hidden or 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 hidden or 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 |
|---|---|---|
| @@ -0,0 +1,6 @@ | ||
| The `composition convert` command converts a Crossplane composition to use a | ||
| different version or migrate away from features that are no longer supported. | ||
|
adamwg marked this conversation as resolved.
|
||
|
|
||
| The currently supported conversions are: | ||
|
|
||
| - Native Composition Environment → `function-environment-configs` | ||
This file contains hidden or 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 |
|---|---|---|
| @@ -0,0 +1,45 @@ | ||
| --- | ||
| weight: 50 | ||
| title: Command Reference | ||
| description: "Command reference for the Crossplane CLI" | ||
| --- | ||
|
|
||
| <!-- This file is generated by `crossplane generate-docs`. Do not edit by hand. --> | ||
|
|
||
| This documentation is for the `crossplane` CLI [[ .Version ]]. | ||
|
|
||
| [[ range .Commands ]] | ||
| <!-- vale Google.Headings = NO --> | ||
| <!-- vale Microsoft.Headings = NO --> | ||
| [[ .Heading ]] [[ .FullPath ]] | ||
| <!-- vale Google.Headings = YES --> | ||
| <!-- vale Microsoft.Headings = YES --> | ||
|
|
||
| [[ if .Help ]][[ .Help ]][[ end ]] | ||
|
|
||
| [[ if .Detail ]][[ .Detail ]][[ end ]] | ||
|
|
||
| [[ .SubHeading ]] Usage | ||
|
|
||
| ``` | ||
| crossplane [[ .Summary ]] | ||
| ``` | ||
| [[- if .Positional ]] | ||
| [[ .SubHeading ]] Arguments | ||
|
|
||
| {{< table "table table-sm table-striped" >}} | ||
| | Argument | Description | | ||
| |----------|-------------| | ||
| [[ range .Positional ]]| `[[ .Display ]]` | [[ if not .Required ]]*(optional)* [[ end ]][[ .Help ]] | | ||
| [[ end ]]{{< /table >}} | ||
| [[ end ]] | ||
| [[- if .Flags ]] | ||
| [[ .SubHeading ]] Flags | ||
|
|
||
| {{< table "table table-sm table-striped" >}} | ||
| | Short flag | Long flag | Description | | ||
| |------------|-----------|-------------| | ||
| [[ range .Flags ]]| [[ if .Short ]]`[[ .Short ]]`[[ end ]] | `[[ .Long ]]` | [[ if .Required ]]**Required.** [[ end ]][[ .Help ]] | | ||
| [[ end ]]{{< /table >}} | ||
| [[ end ]] | ||
| [[ end ]] |
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.