Adding app scaffolding for griptape #57
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: Push Registry App Files to Supabase | |
on: | |
push: | |
branches: | |
- master | |
paths: | |
- 'components/**' | |
jobs: | |
push_to_supabase: | |
name: Push registry app files to Supabase if they have been modified | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
pull-requests: write | |
steps: | |
- uses: actions/checkout@v4.1.7 | |
name: Checkout repo | |
with: | |
# https://github.com/actions/checkout/issues/266#issuecomment-638346893 | |
fetch-depth: 0 | |
- uses: pnpm/action-setup@v4.0.0 | |
with: | |
version: 9.14.2 | |
- name: Get pnpm store directory | |
id: pnpm-cache | |
run: | | |
echo "::set-output name=pnpm_cache_dir::$(pnpm store path)" | |
- uses: actions/cache@v4 | |
name: Setup pnpm cache | |
with: | |
path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }} | |
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} | |
restore-keys: | | |
${{ runner.os }}-pnpm-store- | |
- name: Setup Node Env | |
uses: actions/setup-node@v4.0.3 | |
with: | |
node-version: 18 | |
registry-url: https://registry.npmjs.org/ | |
cache: 'pnpm' | |
- uses: Ana06/get-changed-files@v2.3.0 | |
id: changed_files | |
name: Get changed files | |
with: | |
format: json | |
- name: Upload modified or newly added *.app.mjs files to Supabase | |
uses: ./.github/actions/push-registry-app-files-supabase | |
with: | |
changed_files: ${{ steps.changed_files.outputs.all }} | |
supabase_anon_key: ${{ secrets.SUPABASE_ANON_KEY }} | |
supabase_uri: ${{ secrets.SUPABASE_URI }} |