diff --git a/cmd/oras/root/push.go b/cmd/oras/root/push.go index 601ad3a55..81ecf853a 100644 --- a/cmd/oras/root/push.go +++ b/cmd/oras/root/push.go @@ -59,7 +59,7 @@ func pushCmd() *cobra.Command { Example - Push file "hi.txt" with media type "application/vnd.oci.image.layer.v1.tar" (default): oras push localhost:5000/hello:v1 hi.txt -Example - Push file "hi.txt" and export the pushed manifest to a specified path +Example - Push file "hi.txt" and export the pushed manifest to a specified path: oras push --export-manifest manifest.json localhost:5000/hello:v1 hi.txt Example - Push file "hi.txt" with the custom media type "application/vnd.me.hi": @@ -68,8 +68,12 @@ Example - Push file "hi.txt" with the custom media type "application/vnd.me.hi": Example - Push multiple files with different media types: oras push localhost:5000/hello:v1 hi.txt:application/vnd.me.hi bye.txt:application/vnd.me.bye +Example - Push file "hi.txt" with artifact type "application/vnd.example+type": + oras push --artifact-type application/vnd.example+type localhost:5000/hello:v1 hi.txt + Example - Push file "hi.txt" with config type "application/vnd.me.config": - oras push --artifact-type application/vnd.me.config localhost:5000/hello:v1 hi.txt + oras push --image-spec v1.0 --artifact-type application/vnd.me.config localhost:5000/hello:v1 hi.txt + Example - Push file "hi.txt" with the custom manifest config "config.json" of the custom media type "application/vnd.me.config": oras push --config config.json:application/vnd.me.config localhost:5000/hello:v1 hi.txt @@ -80,10 +84,10 @@ Example - Push file to the insecure registry: Example - Push file to the HTTP registry: oras push --plain-http localhost:5000/hello:v1 hi.txt -Example - Push repository with manifest annotations +Example - Push repository with manifest annotations: oras push --annotation "key=val" localhost:5000/hello:v1 -Example - Push repository with manifest annotation file +Example - Push repository with manifest annotation file: oras push --annotation-file annotation.json localhost:5000/hello:v1 Example - Push file "hi.txt" with multiple tags: