manicmaniac/ApolloDeveloperKit

View on GitHub
.github/workflows/support-new-apollo.yml

Summary

Maintainability
Test Coverage
---
name: Support New Apollo
on:
  repository_dispatch:
    types:
    - support-new-apollo
jobs:
  support-new-apollo:
    if: endsWith(github.event.client_payload.url, '.0')
    runs-on: ubuntu-18.04
    steps:
    - name: Export version
      run: echo "::set-env name=APOLLO_VERSION::$(basename ${{ github.event.client_payload.url }})"
    - uses: actions/checkout@v2
    - name: Make changes
      run: ./bin/support-new-apollo "$APOLLO_VERSION"
    - name: Create pull request
      uses: peter-evans/create-pull-request@v3
      with:
        token: "${{ secrets.PERSONAL_ACCESS_TOKEN }}"
        commit-message: Support Apollo ${{ env.APOLLO_VERSION }}
        branch: support-apollo-${{ env.APOLLO_VERSION }}
        title: Support Apollo ${{ env.APOLLO_VERSION }}
        body: "${{ github.event.client_payload.url }}"