Skip to content

Merge pull request #1 from ethglobal/liam/deploy-script #1

Merge pull request #1 from ethglobal/liam/deploy-script

Merge pull request #1 from ethglobal/liam/deploy-script #1

Workflow file for this run

name: Deploy Project
on:
push:
branches:
- main
workflow_dispatch:
jobs:
deploy:
runs-on: ubuntu-latest
strategy:
matrix:
target: [ethglobal] # add more here for other accounts; implies CLASPRC_{NAME} exists w/ oauth
env:
SCRIPT_ID: "1eKtnybTCz-GKohMdtdEKVDBUzFK3suniSAT0UDEKsM_Fm5dR9aRMs3WN"
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: '16'
- name: Install clasp
run: npm install -g @google/clasp
- name: Set up .clasp.json file
run: |
echo '{"scriptId":"${SCRIPT_ID}","rootDir":"dist"}' > ${{ github.workspace }}/allhands/.clasp.json
- name: Set up OAuth credentials
env:
CLASPRC_CONTENT: ${{ secrets.CLASPRC_${{ matrix.target | upper }} }}

Check failure on line 35 in .github/workflows/deploy.yml

View workflow run for this annotation

GitHub Actions / Deploy Project

Invalid workflow file

The workflow is not valid. .github/workflows/deploy.yml (Line: 35, Col: 28): Unexpected symbol: 'CLASPRC_${{'. Located at position 9 within expression: secrets.CLASPRC_${{ matrix.target | upper
run: |
echo "$CLASPRC_CONTENT" | base64 -d > ~/.clasprc.json
- name: Build the latest
run: npm run build
- name: Deploy ${{ matrix.target }}
run: |
echo "Deploying ${{ matrix.target }}..."
cd ${{ github.workspace }}/allhands
clasp push && echo "Deploying ${{ matrix.target }}... done."