Skip to content

Run CLI

Run CLI #20

Workflow file for this run

name: Run CLI
on:
workflow_dispatch:
inputs:
cli_args:
description: "Commands"
default: fetch
required: true
jobs:
run_cli:
runs-on: ubuntu-latest
steps:
- name: πŸ“₯ Checkout repo
uses: actions/checkout@v3
- name: πŸπŸ› οΈ setup python
uses: actions/setup-python@v4
with:
python-version: "3.11"
# File can be encoded to base64 on https://base64.guru/converter/encode/file
- name: πŸ”‘πŸ”“ Decoding Firebase Admin SDK Credentials
run: echo "${{ secrets.ADMIN_SDK_FIREBASE_CREDS }}" | base64 --decode > adminsdk-creds.json
- name: πŸ“¦πŸ’» install python packages
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: πŸƒβ€β™€οΈπŸπŸ’» execute py script
run: python main.py ${{ inputs.cli_args }}
- name: πŸ“€πŸ“¦ Upload file(s) to artifacts
uses: actions/upload-artifact@v3
with:
path: outputs
- name: πŸ“ Record input(s)
run: |
echo "## Input given:" >> $GITHUB_STEP_SUMMARY
echo \`${{ inputs.cli_args }}\` >> $GITHUB_STEP_SUMMARY