Skip to content

Commit cbb255e

Browse files
fix: fix errors in manifest index examples (#1634)
Signed-off-by: Xiaoxuan Wang <xiaoxuanwang@microsoft.com>
1 parent 555196b commit cbb255e

2 files changed

Lines changed: 4 additions & 1 deletion

File tree

cmd/oras/root/manifest/index/create.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ Example - Create and push an index with annotations:
7676
oras manifest index create localhost:5000/hello:v1 linux-amd64 --annotation "key=val"
7777
7878
Example - Create an index and push to an OCI image layout folder 'layout-dir' and tag with 'v1':
79-
oras manifest index create layout-dir:v1 linux-amd64 sha256:99e4703fbf30916f549cd6bfa9cdbab614b5392fbe64fdee971359a77073cdf9
79+
oras manifest index create --oci-layout layout-dir:v1 linux-amd64 sha256:99e4703fbf30916f549cd6bfa9cdbab614b5392fbe64fdee971359a77073cdf9
8080
8181
Example - Create an index and save it locally to index.json, auto push will be disabled:
8282
oras manifest index create --output index.json localhost:5000/hello linux-amd64 linux-arm64

cmd/oras/root/manifest/index/update.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,9 @@ Example - Merge manifests from the index 'v2-windows' to the index 'v2':
6767
Example - Update an index and tag the updated index as 'v2.1.0' and 'v2':
6868
oras manifest index update localhost:5000/hello@sha256:99e4703fbf30916f549cd6bfa9cdbab614b5392fbe64fdee971359a77073cdf9 --add linux-amd64 --tag "v2.1.0" --tag "v2"
6969
70+
Example - Update an index and push to an OCI image layout folder 'layout-dir' and tag with 'v2':
71+
oras manifest index update --oci-layout layout-dir@99e4703fbf30916f549cd6bfa9cdbab614b5392fbe64fdee971359a77073cdf9 --add linux-arm64 --tag "v2"
72+
7073
Example - Update an index and save it locally to index.json, auto push will be disabled:
7174
oras manifest index update --output index.json localhost:5000/hello:v2 --add v2-linux-amd64
7275

0 commit comments

Comments
 (0)