Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package oras for openSUSE:Factory checked in 
at 2026-03-12 22:22:19
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/oras (Old)
 and      /work/SRC/openSUSE:Factory/.oras.new.8177 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "oras"

Thu Mar 12 22:22:19 2026 rev:7 rq:1338477 version:1.3.1

Changes:
--------
--- /work/SRC/openSUSE:Factory/oras/oras.changes        2025-09-18 
21:12:57.357192149 +0200
+++ /work/SRC/openSUSE:Factory/.oras.new.8177/oras.changes      2026-03-12 
22:27:02.914067615 +0100
@@ -1,0 +2,23 @@
+Thu Mar 12 11:52:03 UTC 2026 - Johannes Kastl 
<[email protected]>
+
+- Update to version 1.3.1:
+  * Bug Fixes
+    - Fix #1903: oras cp should not mount if source and destination
+      credentials are different
+    - Fix #1872: allow setting org.opencontainers.image.title in
+      annotation file
+  * Other Changes
+    - Upgrade to Go 1.26
+    - Update dependencies
+  * What's Changed
+    - fix: cp should not mount if src and dst credentials are
+      different by @wangxiaoxuan273 in #1903
+    - fix: allow setting org.opencontainers.image.title in
+      annotation file by @rafaelgieschke in #1872
+    - build(deps): cherry-pick Go 1.25.7 bump to release-1.3 by
+      @TerryHowe in #1990
+    - build(deps): cherry-pick golang.org/x/crypto bump to
+      release-1.3 by @TerryHowe in #1994
+    - chore: bump Go to 1.26 by @TerryHowe in #2001
+
+-------------------------------------------------------------------

Old:
----
  oras-1.3.0.obscpio

New:
----
  oras-1.3.1.obscpio

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ oras.spec ++++++
--- /var/tmp/diff_new_pack.7HJe6w/_old  2026-03-12 22:27:04.054115393 +0100
+++ /var/tmp/diff_new_pack.7HJe6w/_new  2026-03-12 22:27:04.054115393 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package oras
 #
-# Copyright (c) 2025 SUSE LLC and contributors
+# Copyright (c) 2026 SUSE LLC and contributors
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -17,7 +17,7 @@
 
 
 Name:           oras
-Version:        1.3.0
+Version:        1.3.1
 Release:        0
 Summary:        OCI registry client - manage content like artifacts, images, 
packages
 License:        Apache-2.0
@@ -26,8 +26,8 @@
 Source1:        vendor.tar.gz
 BuildRequires:  bash-completion
 BuildRequires:  fish
+BuildRequires:  go1.26 >= 1.26.1
 BuildRequires:  zsh
-BuildRequires:  golang(API) >= 1.25
 
 %description
 ORAS is the de facto tool for working with OCI Artifacts. It treats media types

++++++ _service ++++++
--- /var/tmp/diff_new_pack.7HJe6w/_old  2026-03-12 22:27:04.094117070 +0100
+++ /var/tmp/diff_new_pack.7HJe6w/_new  2026-03-12 22:27:04.102117405 +0100
@@ -3,7 +3,7 @@
     <param name="url">https://github.com/oras-project/oras</param>
     <param name="scm">git</param>
     <param name="exclude">.git</param>
-    <param name="revision">v1.3.0</param>
+    <param name="revision">v1.3.1</param>
     <param name="versionformat">@PARENT_TAG@</param>
     <param name="versionrewrite-pattern">v(.*)</param>
     <param name="changesgenerate">enable</param>

++++++ _servicedata ++++++
--- /var/tmp/diff_new_pack.7HJe6w/_old  2026-03-12 22:27:04.126118411 +0100
+++ /var/tmp/diff_new_pack.7HJe6w/_new  2026-03-12 22:27:04.130118579 +0100
@@ -1,6 +1,6 @@
 <servicedata>
 <service name="tar_scm">
                 <param name="url">https://github.com/oras-project/oras</param>
-              <param 
name="changesrevision">40530fe4c68e5825b868cd874bd46fc0cdd0f432</param></service></servicedata>
+              <param 
name="changesrevision">e3f584fabe332396414a44b7a83d029cfa5fc201</param></service></servicedata>
 (No newline at EOF)
 

++++++ oras-1.3.0.obscpio -> oras-1.3.1.obscpio ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/oras-1.3.0/CODEOWNERS new/oras-1.3.1/CODEOWNERS
--- old/oras-1.3.0/CODEOWNERS   2025-09-03 10:18:05.000000000 +0200
+++ new/oras-1.3.1/CODEOWNERS   2026-03-12 02:19:59.000000000 +0100
@@ -1,2 +1,2 @@
 # Derived from OWNERS.md
-* @sajayantony @shizhMSFT @stevelasker @qweeah @Wwwsylvia @TerryHowe
+* @sabre1041 @sajayantony @shizhMSFT @Wwwsylvia @TerryHowe
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/oras-1.3.0/Dockerfile new/oras-1.3.1/Dockerfile
--- old/oras-1.3.0/Dockerfile   2025-09-03 10:18:05.000000000 +0200
+++ new/oras-1.3.1/Dockerfile   2026-03-12 02:19:59.000000000 +0100
@@ -11,7 +11,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-FROM --platform=$BUILDPLATFORM docker.io/library/golang:1.25.0-alpine as 
builder
+FROM --platform=$BUILDPLATFORM docker.io/library/golang:1.26.1-alpine as 
builder
 ARG TARGETPLATFORM
 RUN apk add git make
 ENV ORASPKG /oras
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/oras-1.3.0/KEYS new/oras-1.3.1/KEYS
--- old/oras-1.3.0/KEYS 2025-09-03 10:18:05.000000000 +0200
+++ new/oras-1.3.1/KEYS 2026-03-12 02:19:59.000000000 +0100
@@ -66,3 +66,23 @@
 SVi85KgQBA==
 =Ih64
 -----END PGP PUBLIC KEY BLOCK-----
+pub   ed25519 2025-06-06 [SC]
+      2DA461D13B0C27845EDFA77FE462A3894CBAAA47
+uid           [ultimate] Terry Howe <[email protected]>
+sig 3        E462A3894CBAAA47 2025-06-06  [self-signature]
+sub   cv25519 2025-06-06 [E]
+sig          E462A3894CBAAA47 2025-06-06  [self-signature]
+
+-----BEGIN PGP PUBLIC KEY BLOCK-----
+
+mDMEaELDEBYJKwYBBAHaRw8BAQdACwT+K9xzXLTJoPgbbUANEXnCLzej3Er41+YK
+wuAIX2G0IVRlcnJ5IEhvd2UgPHRlcnJ5bGhvd2VAZ21haWwuY29tPoiTBBMWCgA7
+FiEELaRh0TsMJ4Re36d/5GKjiUy6qkcFAmhCwxACGwMFCwkIBwICIgIGFQoJCAsC
+BBYCAwECHgcCF4AACgkQ5GKjiUy6qkftMgEA4HwMQoHj5PSKbW1Dysoi0z/0w77I
+STeuKCmqObZvYHIBAI7c4FfJ6pHDghMBcLgg2CzLbUM2C+C9mLIwKI8C8RUKuDgE
+aELDEBIKKwYBBAGXVQEFAQEHQNqKXMKfLczJCgpjAcNRiHAFJN1n8sYOy6jUCVRF
+hEdWAwEIB4h4BBgWCgAgFiEELaRh0TsMJ4Re36d/5GKjiUy6qkcFAmhCwxACGwwA
+CgkQ5GKjiUy6qkfIYAEAnN+lGbgYfzmB2JIj/qb39teFmciJCU8vfxfkNKeE7FoA
+/jV/gyOIb3rPCBxzkbBOoFi76lGK4GUdEZNU6OJAg1QD
+=ePpx
+-----END PGP PUBLIC KEY BLOCK-----
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/oras-1.3.0/OWNERS.md new/oras-1.3.1/OWNERS.md
--- old/oras-1.3.0/OWNERS.md    2025-09-03 10:18:05.000000000 +0200
+++ new/oras-1.3.1/OWNERS.md    2026-03-12 02:19:59.000000000 +0100
@@ -1,12 +1,14 @@
 # Owners
 
 Owners:
+  - Andrew Block (@sabre1041)
   - Sajay Antony (@sajayantony)
   - Shiwei Zhang (@shizhMSFT)
-  - Steve Lasker (@stevelasker)
+  - Terry Howe (@TerryHowe)
 
 Emeritus:
   - Avi Deitcher (@deitch)
   - Jimmy Zelinskie (@jzelinskie)
   - Josh Dolitsky (@jdolitsky)
+  - Steve Lasker (@stevelasker)
   - Vincent Batts (@vbatts)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/oras-1.3.0/cmd/oras/root/cp.go 
new/oras-1.3.1/cmd/oras/root/cp.go
--- old/oras-1.3.0/cmd/oras/root/cp.go  2025-09-03 10:18:05.000000000 +0200
+++ new/oras-1.3.1/cmd/oras/root/cp.go  2026-03-12 02:19:59.000000000 +0100
@@ -172,11 +172,9 @@
                return registry.Referrers(ctx, src, desc, "")
        }
 
-       srcRepo, srcIsRemote := src.(*remote.Repository)
-       dstRepo, dstIsRemote := dst.(*remote.Repository)
-       if srcIsRemote && dstIsRemote && srcRepo.Reference.Registry == 
dstRepo.Reference.Registry {
+       if mountRepo, canMount := getMountPoint(src, dst, opts); canMount {
                extendedCopyGraphOptions.MountFrom = func(ctx context.Context, 
desc ocispec.Descriptor) ([]string, error) {
-                       return []string{srcRepo.Reference.Repository}, nil
+                       return []string{mountRepo}, nil
                }
        }
        dst, err = copyHandler.StartTracking(dst)
@@ -313,3 +311,23 @@
        }
        return opts, root, nil
 }
+
+// getMountPoint checks if mounting can be performed between two targets and 
returns
+// the repository name to be mounted from if applicable. Mount can be 
performed if the two
+// targets are both remote repositories, are in the same registry and have 
identical credentials.
+func getMountPoint(src oras.ReadOnlyGraphTarget, dst oras.GraphTarget, opts 
*copyOptions) (string, bool) {
+       srcRepo, srcIsRemote := src.(*remote.Repository)
+       dstRepo, dstIsRemote := dst.(*remote.Repository)
+       if !srcIsRemote || !dstIsRemote {
+               return "", false
+       }
+       if srcRepo.Reference.Registry != dstRepo.Reference.Registry {
+               return "", false
+       }
+       srcCred := opts.From.Credential()
+       dstCred := opts.To.Credential()
+       if srcCred != dstCred {
+               return "", false
+       }
+       return srcRepo.Reference.Repository, true
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/oras-1.3.0/cmd/oras/root/cp_test.go 
new/oras-1.3.1/cmd/oras/root/cp_test.go
--- old/oras-1.3.0/cmd/oras/root/cp_test.go     2025-09-03 10:18:05.000000000 
+0200
+++ new/oras-1.3.1/cmd/oras/root/cp_test.go     2026-03-12 02:19:59.000000000 
+0100
@@ -364,3 +364,90 @@
                t.Errorf("prepareCopyOption() error = %v, wantErr false", err)
        }
 }
+
+func Test_getMountPoint(t *testing.T) {
+       registry1Repo1 := &remote.Repository{}
+       registry1Repo1.Reference.Registry = "localhost:5000"
+       registry1Repo1.Reference.Repository = "repo1"
+
+       registry1Repo2 := &remote.Repository{}
+       registry1Repo2.Reference.Registry = "localhost:5000"
+       registry1Repo2.Reference.Repository = "repo2"
+
+       registry2Repo1 := &remote.Repository{}
+       registry2Repo1.Reference.Registry = "localhost:6000"
+       registry2Repo1.Reference.Repository = "repo1"
+
+       tests := []struct {
+               name         string
+               src          oras.ReadOnlyGraphTarget
+               dst          oras.GraphTarget
+               fromUsername string
+               fromPassword string
+               toUsername   string
+               toPassword   string
+               wantRepo     bool
+               wantMount    string
+       }{
+               {
+                       name:         "should mount: both remote, same 
registry, same credentials",
+                       src:          registry1Repo1,
+                       dst:          registry1Repo2,
+                       fromUsername: "user1",
+                       fromPassword: "pass1",
+                       toUsername:   "user1",
+                       toPassword:   "pass1",
+                       wantRepo:     true,
+                       wantMount:    "repo1",
+               },
+               {
+                       name:         "should not mount: both remote, same 
registry, different credentials",
+                       src:          registry1Repo1,
+                       dst:          registry1Repo2,
+                       fromUsername: "user1",
+                       fromPassword: "pass1",
+                       toUsername:   "user2",
+                       toPassword:   "pass2",
+                       wantRepo:     false,
+                       wantMount:    "",
+               },
+               {
+                       name:         "should not mount: both remote, different 
registries",
+                       src:          registry1Repo1,
+                       dst:          registry2Repo1,
+                       fromUsername: "user1",
+                       fromPassword: "pass1",
+                       toUsername:   "user3",
+                       toPassword:   "pass3",
+                       wantRepo:     false,
+                       wantMount:    "",
+               },
+               {
+                       name:       "should not mount: source is not remote",
+                       src:        memStore,
+                       dst:        registry1Repo1,
+                       toUsername: "user1",
+                       toPassword: "pass1",
+                       wantRepo:   false,
+                       wantMount:  "",
+               },
+       }
+
+       for _, tt := range tests {
+               t.Run(tt.name, func(t *testing.T) {
+                       opts := &copyOptions{}
+                       opts.From.Username = tt.fromUsername
+                       opts.From.Secret = tt.fromPassword
+                       opts.To.Username = tt.toUsername
+                       opts.To.Secret = tt.toPassword
+
+                       gotMount, gotRepo := getMountPoint(tt.src, tt.dst, opts)
+                       if gotRepo != tt.wantRepo {
+                               t.Errorf("checkMount() gotRepo = %v, want %v", 
gotRepo, tt.wantRepo)
+                       }
+                       if gotMount != tt.wantMount {
+                               t.Errorf("checkMount() gotRepo = %v, want %v", 
gotMount, tt.wantMount)
+                       }
+               })
+       }
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/oras-1.3.0/cmd/oras/root/file.go 
new/oras-1.3.1/cmd/oras/root/file.go
--- old/oras-1.3.0/cmd/oras/root/file.go        2025-09-03 10:18:05.000000000 
+0200
+++ new/oras-1.3.1/cmd/oras/root/file.go        2026-03-12 02:19:59.000000000 
+0100
@@ -41,6 +41,12 @@
                        name = filepath.ToSlash(name)
                }
 
+               if value, ok := annotations[filename]; ok {
+                       if nameFromAnnotations, ok := 
value[ocispec.AnnotationTitle]; ok {
+                               name = nameFromAnnotations
+                       }
+               }
+
                err = displayStatus.OnFileLoading(name)
                if err != nil {
                        return nil, err
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/oras-1.3.0/go.mod new/oras-1.3.1/go.mod
--- old/oras-1.3.0/go.mod       2025-09-03 10:18:05.000000000 +0200
+++ new/oras-1.3.1/go.mod       2026-03-12 02:19:59.000000000 +0100
@@ -1,6 +1,6 @@
 module oras.land/oras
 
-go 1.25.0
+go 1.26.1
 
 require (
        github.com/Masterminds/sprig/v3 v3.3.0
@@ -12,7 +12,7 @@
        github.com/spf13/cobra v1.10.1
        github.com/spf13/pflag v1.0.9
        golang.org/x/sync v0.16.0
-       golang.org/x/term v0.34.0
+       golang.org/x/term v0.37.0
        gopkg.in/yaml.v3 v3.0.1
        oras.land/oras-go/v2 v2.6.0
 )
@@ -28,6 +28,6 @@
        github.com/mitchellh/reflectwalk v1.0.2 // indirect
        github.com/shopspring/decimal v1.4.0 // indirect
        github.com/spf13/cast v1.9.2 // indirect
-       golang.org/x/crypto v0.40.0 // indirect
-       golang.org/x/sys v0.35.0 // indirect
+       golang.org/x/crypto v0.45.0 // indirect
+       golang.org/x/sys v0.38.0 // indirect
 )
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/oras-1.3.0/go.sum new/oras-1.3.1/go.sum
--- old/oras-1.3.0/go.sum       2025-09-03 10:18:05.000000000 +0200
+++ new/oras-1.3.1/go.sum       2026-03-12 02:19:59.000000000 +0100
@@ -54,16 +54,16 @@
 github.com/stretchr/objx v0.1.0/go.mod 
h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
 github.com/stretchr/testify v1.7.0 
h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY=
 github.com/stretchr/testify v1.7.0/go.mod 
h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
-golang.org/x/crypto v0.40.0 h1:r4x+VvoG5Fm+eJcxMaY8CQM7Lb0l1lsmjGBQ6s8BfKM=
-golang.org/x/crypto v0.40.0/go.mod 
h1:Qr1vMER5WyS2dfPHAlsOj01wgLbsyWtFn/aY+5+ZdxY=
+golang.org/x/crypto v0.45.0 h1:jMBrvKuj23MTlT0bQEOBcAE0mjg8mK9RXFhRH6nyF3Q=
+golang.org/x/crypto v0.45.0/go.mod 
h1:XTGrrkGJve7CYK7J8PEww4aY7gM3qMCElcJQ8n8JdX4=
 golang.org/x/sync v0.16.0 h1:ycBJEhp9p4vXvUZNszeOq0kGTPghopOL8q0fq3vstxw=
 golang.org/x/sync v0.16.0/go.mod 
h1:1dzgHSNfp02xaA81J2MS99Qcpr2w7fw1gpm99rleRqA=
 golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod 
h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
 golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
-golang.org/x/sys v0.35.0 h1:vz1N37gP5bs89s7He8XuIYXpyY0+QlsKmzipCbUtyxI=
-golang.org/x/sys v0.35.0/go.mod h1:BJP2sWEmIv4KK5OTEluFJCKSidICx8ciO85XgH3Ak8k=
-golang.org/x/term v0.34.0 h1:O/2T7POpk0ZZ7MAzMeWFSg6S5IpWd/RXDlM9hgM3DR4=
-golang.org/x/term v0.34.0/go.mod 
h1:5jC53AEywhIVebHgPVeg0mj8OD3VO9OzclacVrqpaAw=
+golang.org/x/sys v0.38.0 h1:3yZWxaJjBmCWXqhN1qh02AkOnCQ1poK6oF+a7xWL6Gc=
+golang.org/x/sys v0.38.0/go.mod h1:OgkHotnGiDImocRcuBABYBEXf8A9a87e/uXjp9XT3ks=
+golang.org/x/term v0.37.0 h1:8EGAD0qCmHYZg6J17DvsMy9/wJ7/D/4pV/wfnld5lTU=
+golang.org/x/term v0.37.0/go.mod 
h1:5pB4lxRNYYVZuTLmy8oR2BH8dflOR+IbTYFD8fi3254=
 gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 
h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
 gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod 
h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
 gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod 
h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/oras-1.3.0/internal/version/version.go 
new/oras-1.3.1/internal/version/version.go
--- old/oras-1.3.0/internal/version/version.go  2025-09-03 10:18:05.000000000 
+0200
+++ new/oras-1.3.1/internal/version/version.go  2026-03-12 02:19:59.000000000 
+0100
@@ -17,9 +17,9 @@
 
 var (
        // Version is the current version of the oras.
-       Version = "1.3.0"
+       Version = "1.3.1"
        // BuildMetadata is the extra build time data
-       BuildMetadata = "unreleased"
+       BuildMetadata = ""
        // GitCommit is the git sha1
        GitCommit = ""
        // GitTreeState is the state of the git tree
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/oras-1.3.0/test/e2e/go.mod 
new/oras-1.3.1/test/e2e/go.mod
--- old/oras-1.3.0/test/e2e/go.mod      2025-09-03 10:18:05.000000000 +0200
+++ new/oras-1.3.1/test/e2e/go.mod      2026-03-12 02:19:59.000000000 +0100
@@ -1,6 +1,6 @@
 module oras.land/oras/test/e2e
 
-go 1.25.0
+go 1.26.1
 
 require (
        github.com/onsi/ginkgo/v2 v2.25.2
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/oras-1.3.0/test/e2e/go.work 
new/oras-1.3.1/test/e2e/go.work
--- old/oras-1.3.0/test/e2e/go.work     2025-09-03 10:18:05.000000000 +0200
+++ new/oras-1.3.1/test/e2e/go.work     2026-03-12 02:19:59.000000000 +0100
@@ -1,4 +1,4 @@
-go 1.25.0
+go 1.26.1
 
 use (
        .
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/oras-1.3.0/test/e2e/suite/command/push.go 
new/oras-1.3.1/test/e2e/suite/command/push.go
--- old/oras-1.3.0/test/e2e/suite/command/push.go       2025-09-03 
10:18:05.000000000 +0200
+++ new/oras-1.3.1/test/e2e/suite/command/push.go       2026-03-12 
02:19:59.000000000 +0100
@@ -380,6 +380,21 @@
                        Expect(len(manifest.Layers)).To(Equal(1))
                        
Expect(manifest.Layers[0].Annotations["foo"]).To(Equal("bar"))
                })
+
+               It("should allow renaming files using customized file 
annotation", func() {
+                       repo := pushTestRepo("file-annotation-rename")
+                       tempDir := PrepareTempFiles()
+
+                       ORAS("push", RegistryRef(ZOTHost, repo, tag), 
foobar.FileBarName, "--annotation-file", "foobar/annotation-rename.json", 
"--config", foobar.FileConfigName).
+                               WithWorkDir(tempDir).Exec()
+
+                       // validate
+                       // see testdata\files\foobar\annotation-rename.json
+                       fetched := ORAS("manifest", "fetch", 
RegistryRef(ZOTHost, repo, tag)).Exec().Out.Contents()
+                       var manifest ocispec.Manifest
+                       Expect(json.Unmarshal(fetched, 
&manifest)).ShouldNot(HaveOccurred())
+                       
Expect(manifest.Layers[0].Annotations["org.opencontainers.image.title"]).To(Equal("foobar/baz"))
+               })
        })
 
        When("pushing to OCI spec v1.1 registries", func() {
@@ -741,5 +756,20 @@
                        Expect(len(manifest.Layers)).To(Equal(1))
                        
Expect(manifest.Layers[0].Annotations["foo"]).To(Equal("bar"))
                })
+
+               It("should allow renaming files using customized file 
annotation", func() {
+                       tempDir := PrepareTempFiles()
+                       ref := LayoutRef(tempDir, tag)
+                       // test
+                       ORAS("push", ref, Flags.Layout, foobar.FileBarName, 
"--annotation-file", "foobar/annotation-rename.json", "--config", 
foobar.FileConfigName).
+                               WithWorkDir(tempDir).Exec()
+
+                       // validate
+                       // see testdata\files\foobar\annotation-rename.json
+                       fetched := ORAS("manifest", "fetch", ref, 
Flags.Layout).Exec().Out.Contents()
+                       var manifest ocispec.Manifest
+                       Expect(json.Unmarshal(fetched, 
&manifest)).ShouldNot(HaveOccurred())
+                       
Expect(manifest.Layers[0].Annotations["org.opencontainers.image.title"]).To(Equal("foobar/baz"))
+               })
        })
 })
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/oras-1.3.0/test/e2e/testdata/files/foobar/annotation-rename.json 
new/oras-1.3.1/test/e2e/testdata/files/foobar/annotation-rename.json
--- old/oras-1.3.0/test/e2e/testdata/files/foobar/annotation-rename.json        
1970-01-01 01:00:00.000000000 +0100
+++ new/oras-1.3.1/test/e2e/testdata/files/foobar/annotation-rename.json        
2026-03-12 02:19:59.000000000 +0100
@@ -0,0 +1 @@
+{"$config":{"hello":"config"},"$manifest":{"hi":"manifest"},"foobar/bar":{"foo":"bar","org.opencontainers.image.title":"foobar/baz"}}

++++++ oras.obsinfo ++++++
--- /var/tmp/diff_new_pack.7HJe6w/_old  2026-03-12 22:27:04.618139032 +0100
+++ /var/tmp/diff_new_pack.7HJe6w/_new  2026-03-12 22:27:04.622139200 +0100
@@ -1,5 +1,5 @@
 name: oras
-version: 1.3.0
-mtime: 1756887485
-commit: 40530fe4c68e5825b868cd874bd46fc0cdd0f432
+version: 1.3.1
+mtime: 1773278399
+commit: e3f584fabe332396414a44b7a83d029cfa5fc201
 

++++++ vendor.tar.gz ++++++
++++ 5347 lines of diff (skipped)

Reply via email to