Skip to content

chore: add react-native-permissions for location handling (#358) #189

chore: add react-native-permissions for location handling (#358)

chore: add react-native-permissions for location handling (#358) #189

name: Marketplace Release
on:
push:
tags:
- "*-native-v*"
jobs:
publish_release:
name: "Marketplace Release"
runs-on: ubuntu-latest
steps:
- name: "Checking-out code"
uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # v3
with:
submodules: false
- name: "Defining Environment Variables"
id: variables
run: echo "tag=$(git tag --points-at HEAD)" >> ${{ runner.os == 'Windows' && '$env:GITHUB_OUTPUT' || '$GITHUB_OUTPUT' }}
- name: "Defining scope"
uses: jungwinter/split@c185fe95439c136a8788b7f700bd5275920d7109 # v1
id: scope
with:
msg: "${{ steps.variables.outputs.tag }}"
seperator: "-v"
- name: "Defining node version"
uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c # v3
with:
node-version-file: ".nvmrc"
- name: "Installing dependencies"
run: yarn install
- name: "Building native widgets and js actions"
run: yarn workspaces foreach --all run release
- name: "Updating Native Mobile Resources project"
run: yarn workspaces foreach --all run create-modules
env:
GH_USERNAME: ${{ secrets.GH_USERNAME }}
GH_EMAIL: ${{ secrets.GH_EMAIL }}
GH_NAME: ${{ secrets.GH_NAME }}
GH_PAT: ${{ secrets.GH_PAT }}
TAG: ${{ steps.variables.outputs.tag }}
- name: "Check changes and publish package ${{ steps.variables.outputs.tag }}"
run: yarn workspace ${{ steps.scope.outputs._0 }} run release:marketplace
env:
OPENID_URL: ${{ secrets.OPENID_URL }}
CPAPI_USERNAME: ${{ secrets.CPAPI_USERNAME }}
CPAPI_PASS_PROD: ${{ secrets.CPAPI_PASS_PROD }}
TAG: ${{ steps.variables.outputs.tag }}
- name: "Send slack msg on failure"
if: ${{ failure() }}
uses: ./.github/actions/slack-notification
with:
channel-id: ${{ secrets.SLACK_CHANNEL_ID }}
message: |
:warning: *Automation Failed*
Something went wrong while uploading version ${{ steps.scope.outputs._1 }} of package ${{ steps.scope.outputs._0 }} to the marketplace. <https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}|More info..>
bot-token: ${{ secrets.SLACK_BOT_TOKEN }}