Skip to content

Commit 87163ba

Browse files
committed
fix(ci): pin whatsmeow-lib SHA from dev repo in sync-releases
The sync workflow was re-cloning whatsmeow main on every sync, which meant the SHA fixed on develop (and cited in CHANGELOG) was not propagated to evolution-go / evolution-go-beta. This broke release reproducibility: a public build of vX.Y.Z could differ from the equivalent dev snapshot whenever whatsmeow main moved. Capture the dev-side submodule SHA before touching the target repo, then run submodule add + checkout that exact commit in the target. Addresses checklist item #5 of tools/docs/RELEASE_PROCESS.md (whatsmeow-lib está no commit correto).
1 parent 9d37fb7 commit 87163ba

1 file changed

Lines changed: 7 additions & 5 deletions

File tree

.github/workflows/sync-releases.yml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -112,14 +112,16 @@ jobs:
112112
113113
- name: Setup whatsmeow-lib
114114
run: |
115+
WHATSMEOW_SHA=$(cd ${{ github.workspace }}/whatsmeow-lib && git rev-parse HEAD)
116+
echo "Pinning whatsmeow-lib to $WHATSMEOW_SHA (from dev repo)"
115117
cd ${{ steps.target.outputs.dir }}
116118
git rm -rf whatsmeow-lib 2>/dev/null || true
117119
rm -rf whatsmeow-lib .gitmodules
118-
printf '[submodule "whatsmeow-lib"]\n\tpath = whatsmeow-lib\n\turl = https://github.com/EvolutionAPI/whatsmeow.git\n' > .gitmodules
119-
git add .gitmodules
120-
git clone https://github.com/EvolutionAPI/whatsmeow.git whatsmeow-lib
121-
git submodule init
122-
git submodule update
120+
git submodule add -f https://github.com/EvolutionAPI/whatsmeow.git whatsmeow-lib
121+
cd whatsmeow-lib
122+
git checkout "$WHATSMEOW_SHA"
123+
cd ..
124+
git add .gitmodules whatsmeow-lib
123125
124126
- name: Clean artifacts
125127
run: |

0 commit comments

Comments
 (0)