Skip to content

Commit

Permalink
chore: Generate main commands page (#360)
Browse files Browse the repository at this point in the history
Generate the main commands page.

Signed-off-by: Terry Howe <[email protected]>
  • Loading branch information
Terry Howe authored Jul 9, 2024
1 parent c15bdfe commit f5e6c4d
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 12 deletions.
16 changes: 16 additions & 0 deletions tools/parse_main.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/usr/bin/env bash

echo '---'
echo "title: Use the ORAS command line"
echo "sidebar_position: 0"
echo 'warning: Do NOT modify this generated file'
echo '---'
echo
echo '# Use the ORAS command line'
echo
echo 'To list available commands, either run `oras` with no parameters or execute `oras help`:'
echo
echo '```'
cat
echo '```'
echo
1 change: 1 addition & 0 deletions tools/refresh-commands.sh
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ do
ORAS_COMMAND=$(./tools/install.sh ${LATEST_VERSION} ${TEMPDIR})
WEIGHT=10
VERSIONED_DOCS=versioned_docs/version-${VERSION}/commands
${ORAS_COMMAND} help | ./tools/parse_main.sh >"${VERSIONED_DOCS}/use_oras_cli.mdx"
list_commands >"${TEMPDIR}/commands"
while read COMMAND
do
Expand Down
12 changes: 6 additions & 6 deletions versioned_docs/version-1.1/commands/use_oras_cli.mdx
Original file line number Diff line number Diff line change
@@ -1,31 +1,31 @@
---
title: Use the ORAS command line
sidebar_position: 0
warning: Do NOT modify this generated file
---

# Use the ORAS command line

To list available commands, either run `oras` with no parameters or execute `oras help`:

```
$ oras
Usage:
oras [command]
Available Commands:
attach Attach files to an existing artifact
attach [Preview] Attach files to an existing artifact
blob Blob operations
completion Generate the autocompletion script for the specified shell
cp Copy artifacts from one target to another
discover Discover referrers of a manifest in the remote registry
discover [Preview] Discover referrers of a manifest in a registry or an OCI image layout
help Help about any command
login Log in to a remote registry
logout Log out from a remote registry
manifest Manifest operations
pull Pull files from remote registry
push Push files to remote registry
pull Pull files from a registry or an OCI image layout
push Push files to a registry or an OCI image layout
repo Repository operations
tag Tag a manifest in the remote registry
tag Tag a manifest in a registry or an OCI image layout
version Show the oras version information
Flags:
Expand Down
13 changes: 7 additions & 6 deletions versioned_docs/version-1.2/commands/use_oras_cli.mdx
Original file line number Diff line number Diff line change
@@ -1,31 +1,32 @@
---
title: Use the ORAS command line
sidebar_position: 0
warning: Do NOT modify this generated file
---

# Use the ORAS command line

To list available commands, either run `oras` with no parameters or execute `oras help`:

```
$ oras
Usage:
oras [command]
Available Commands:
attach Attach files to an existing artifact
attach [Preview] Attach files to an existing artifact
blob Blob operations
completion Generate the autocompletion script for the specified shell
cp Copy artifacts from one target to another
discover Discover referrers of a manifest in the remote registry
discover [Preview] Discover referrers of a manifest in a registry or an OCI image layout
help Help about any command
login Log in to a remote registry
logout Log out from a remote registry
manifest Manifest operations
pull Pull files from remote registry
push Push files to remote registry
pull Pull files from a registry or an OCI image layout
push Push files to a registry or an OCI image layout
repo Repository operations
tag Tag a manifest in the remote registry
resolve [Experimental] Resolves digest of the target artifact
tag Tag a manifest in a registry or an OCI image layout
version Show the oras version information
Flags:
Expand Down

0 comments on commit f5e6c4d

Please sign in to comment.