mirror of
https://github.com/FranP-code/Baileys.git
synced 2025-10-13 00:32:22 +00:00
ci: Updated workflow to update src/Defaults/baileys-version.json file
This commit is contained in:
13
.github/workflows/update-proto.yml
vendored
13
.github/workflows/update-proto.yml
vendored
@@ -20,7 +20,7 @@ jobs:
|
|||||||
- name: Install Node
|
- name: Install Node
|
||||||
uses: actions/setup-node@v3
|
uses: actions/setup-node@v3
|
||||||
with:
|
with:
|
||||||
node-version: 16.x
|
node-version: 18.x
|
||||||
|
|
||||||
- name: Install packages
|
- name: Install packages
|
||||||
run: |
|
run: |
|
||||||
@@ -39,14 +39,21 @@ jobs:
|
|||||||
- name: GenerateStatics
|
- name: GenerateStatics
|
||||||
run: yarn gen:protobuf
|
run: yarn gen:protobuf
|
||||||
|
|
||||||
|
- name: Update baileys-version.json
|
||||||
|
run: |
|
||||||
|
WA_VERSION="${{steps.wa_proto_info.outputs.wa_version}}"
|
||||||
|
WA_NUMBERS=$(echo $WA_VERSION | sed "s/\./, /g")
|
||||||
|
echo -e "{\n\t\"version\": [$WA_NUMBERS]\n}" > src/Defaults/baileys-version.json
|
||||||
|
|
||||||
- name: Create Pull Request
|
- name: Create Pull Request
|
||||||
uses: peter-evans/create-pull-request@v5
|
uses: peter-evans/create-pull-request@v5
|
||||||
with:
|
with:
|
||||||
commit-message: "chore: updated proto to v${{steps.wa_proto_info.outputs.wa_version}}"
|
commit-message: "chore: updated proto/version to v${{steps.wa_proto_info.outputs.wa_version}}"
|
||||||
title: "Whatsapp v${{steps.wa_proto_info.outputs.wa_version}} proto change"
|
title: "Whatsapp v${{steps.wa_proto_info.outputs.wa_version}} proto/version change"
|
||||||
branch: "update-proto/stable"
|
branch: "update-proto/stable"
|
||||||
delete-branch: true
|
delete-branch: true
|
||||||
labels: "update-proto"
|
labels: "update-proto"
|
||||||
body: "Automated changes\nFound source JS URL: ${{steps.wa_proto_info.outputs.wa_js_url}}\nCurrent version: v${{steps.wa_proto_info.outputs.wa_version}}"
|
body: "Automated changes\nFound source JS URL: ${{steps.wa_proto_info.outputs.wa_js_url}}\nCurrent version: v${{steps.wa_proto_info.outputs.wa_version}}"
|
||||||
add-paths: |
|
add-paths: |
|
||||||
WAProto/*
|
WAProto/*
|
||||||
|
src/Defaults/baileys-version.json
|
||||||
|
|||||||
Reference in New Issue
Block a user