From 2410d887dfef586012487204bb6aad40f8337b31 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joakim=20J=C3=A4derberg?= Date: Wed, 14 Jan 2026 12:46:25 +0000 Subject: [PATCH] Merged in chore/include-tags-when-syncing-2 (pull request #3431) actively fetch and push tags when syncing master -> test * actively fetch and push tags when syncing master -> test * git fetch --all --tags Approved-by: Anton Gunnarsson --- netlify/netlify-plugin-branch-sync/index.js | 12 +++++++++++- package.json | 1 + 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/netlify/netlify-plugin-branch-sync/index.js b/netlify/netlify-plugin-branch-sync/index.js index cee5604c3..f3d334ec8 100644 --- a/netlify/netlify-plugin-branch-sync/index.js +++ b/netlify/netlify-plugin-branch-sync/index.js @@ -119,7 +119,15 @@ export const onPreBuild = async function ({ utils }) { // Always fetch to ensure FETCH_HEAD is available logger.debug(`Fetching from origin`) - await run("git", ["-C", CLONE_DIR, "fetch", "origin", SYNC_SOURCE]) + await run("git", [ + "-C", + CLONE_DIR, + "fetch", + "--all", + "--tags", + "origin", + SYNC_SOURCE, + ]) logger.debug(`Attempting to sync: ${SYNC_DEST.join(", ")}`) @@ -135,6 +143,8 @@ export const onPreBuild = async function ({ utils }) { console.log(`Successfully synced '${branch}' with '${SYNC_SOURCE}'`) } + await run("git", ["-C", CLONE_DIR, "push", "origin", "--tags"]) + utils.status.show({ title: "Branch sync", summary: "All branches are synced! ✅", diff --git a/package.json b/package.json index 1f60d08cd..602756597 100644 --- a/package.json +++ b/package.json @@ -28,6 +28,7 @@ "i18n:pull": "yarn i18n:download && yarn i18n:compile && yarn i18n:distribute", "i18n:sync": "yarn i18n:push && yarn i18n:pull", "i18n:syncDefaultMessage": "yarn i18n:download && bun scripts/i18n/syncDefaultMessage/index.ts scripts/i18n/translations/en.json '{apps,packages}/**/*.{tsx,ts}' && yarn format --force", + "deploy:test": "yarn dlx tsx scripts/deploy/deploy.ts test", "deploy:stage": "yarn dlx tsx scripts/deploy/deploy.ts stage", "deploy:preprod": "yarn dlx tsx scripts/deploy/deploy.ts preprod", "deploy:prod": "yarn dlx tsx scripts/deploy/deploy.ts prod"