From f00cf8f24f5532cf3da307c720adefdb4613708e Mon Sep 17 00:00:00 2001
From: Soumyadeep Ghosh <soumyadeepghosh2004@zohomail.in>
Date: Fri, 14 Jun 2024 23:28:23 +0530
Subject: [PATCH] ci: restrict arches for core24

---
 release-to-candidate/action.yaml | 1 +
 1 file changed, 1 insertion(+)

diff --git a/release-to-candidate/action.yaml b/release-to-candidate/action.yaml
index 6854831..f7b829d 100644
--- a/release-to-candidate/action.yaml
+++ b/release-to-candidate/action.yaml
@@ -118,6 +118,7 @@ runs:
           # `core24` uses platforms syntax rather than `architectures`:
           # https://snapcraft.io/docs/architectures
           SNAPCRAFT_REMOTE_BUILD_STRATEGY=disable-fallback
+          yq -i '.platforms |= {env(arch): {"build-on": env(arch)}}' "$yaml_path"
           snapcraft_args+=("--platform $arch")
         elif [[ "${{ steps.setup.outputs.new-remote-build }}" == "false" || "$SNAPCRAFT_REMOTE_BUILD_STRATEGY" == "force-fallback" ]]; then
           # Restrict arch definition to one only in snapcraft.yaml due to: