This repository has been archived by the owner on Jul 23, 2024. It is now read-only.
Testing - deploy all #6
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: "SDK publish on release TEST" | |
on: | |
workflow_run: | |
workflows: ["testing-test"] | |
branches: [main] | |
types: | |
- completed | |
push: | |
branches: [devops/update-cicd-pipeline] | |
jobs: | |
build: | |
permissions: write-all | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Setup Node | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 16 | |
registry-url: https://registry.npmjs.org/ | |
- name: Setup Python | |
uses: actions/setup-python@v4 | |
- name: Setup Java | |
uses: actions/setup-java@v3 | |
with: | |
distribution: 'temurin' | |
java-version: '11' | |
- name: generate code and namespace | |
shell: bash | |
run: | | |
cd web3rpc/codegen && gradle wrapper && gradle wrapper clean :deployJar && cd - &&\ | |
cd web3rpc/rpc-specs && npm install && bash -x generate-namespace.sh && cd | |
- name: Verify Changed files | |
uses: tj-actions/changed-files@v39 | |
id: verify-changed-files | |
with: | |
files_yaml: | | |
ethers-ext: | |
- "ethers-ext/package.json" | |
web3js-ext: | |
- "web3js-ext/package.json" | |
web3j-ext: | |
- "web3j-ext/web3j-ext/build.gradle" | |
web3py-ext: | |
- "web3py-ext/setup.py" | |
web3rpc: | |
- "web3rpc/rpc-specs/**" | |
- name: generate web3py-ext sdk | |
if: steps.verify-changed-files.outputs.web3py-ext_any_changed == 'true' | |
shell: bash | |
run: | | |
cd web3py-ext &&\ | |
python -m pip install build wheel twine &&\ | |
ls -ls &&\ | |
python setup.py bdist_wheel &&\ | |
cd - | |
- name: Publish web3py-ext sdk | |
if: steps.verify-changed-files.outputs.web3py-ext_any_changed == 'true' | |
shell: bash | |
run: | | |
echo "OK" | |
- name: Publish web3j-ext | |
if: steps.verify-changed-files.outputs.web3j-ext_any_changed == 'true' | |
shell: bash | |
run: | | |
echo "OK" | |
- name: generate ethers-ext sdk | |
if: steps.verify-changed-files.outputs.ethers-ext_any_changed == 'true' | |
shell: bash | |
run: | | |
cd ethers-ext && npm install && npm run build && cd - | |
- name: publish ethers-ext sdk | |
if: steps.verify-changed-files.outputs.ethers-ext_any_changed == 'true' | |
shell: bash | |
run: | | |
echo "OK" | |
- name: generate web3rpc-javascript sdk | |
if: steps.verify-changed-files.outputs.web3rpc_any_changed == 'true' | |
shell: bash | |
run: | | |
cd web3rpc/sdk/client/javascript && bash -x javascript-generate.sh && cd - | |
- name: publish web3rpc-javascript sdk | |
if: steps.verify-changed-files.outputs.web3rpc_any_changed == 'true' | |
shell: bash | |
run: | | |
echo "OK" | |
- name: generate web3rpc-java sdk | |
if: steps.verify-changed-files.outputs.web3rpc_any_changed == 'true' | |
shell: bash | |
run: | | |
cd web3rpc/sdk/client/java && bash -x java-generate.sh && cd - | |
env: | |
MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }} | |
MAVEN_PASSWORD: ${{ secrets.MAVEN_PASSWORD }} | |
ORG_GRADLE_PROJECT_SIGNINGPASSWORD: ${{ secrets.ORG_GRADLE_PROJECT_SIGNINGPASSWORD }} | |
ORG_GRADLE_PROJECT_SIGNINGKEY: ${{ secrets.ORG_GRADLE_PROJECT_SIGNINGKEY }} | |
- name: Publish web3rpc-java sdk | |
if: steps.verify-changed-files.outputs.web3rpc_any_changed == 'true' | |
shell: bash | |
run: | | |
echo "OK" |