Skip to content

cli

cli #345

Workflow file for this run

name: cli
on:
workflow_dispatch:
schedule:
# run once per hour
- cron: '0 0 * * *'
jobs:
publish:
name: Publish Prisma CLI
runs-on: macos-14
permissions:
pull-requests: write
contents: write
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 18.x
- name: Publish the latest CLI
run: sh publish-latest.sh
id: publish
working-directory: ./binaries
env:
AWS_DEFAULT_REGION: eu-west-1
AWS_ACCESS_KEY_ID: ${{ secrets.PRISMA_CLI_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.PRISMA_CLI_AWS_SECRET_ACCESS_KEY }}
- name: Create Pull Request
id: pr
uses: peter-evans/create-pull-request@v6
with:
title: 'chore(prisma): upgrade prisma to v${{ steps.publish.outputs.PRISMA_VERSION }}'
body: |
Upgrade prisma to `v${{ steps.publish.outputs.PRISMA_VERSION }}` with engine hash `${{ steps.publish.outputs.PRISMA_HASH }}`.
Full release notes: [v${{ steps.publish.outputs.PRISMA_VERSION }}](https://github.com/prisma/prisma/releases/tag/${{ steps.publish.outputs.PRISMA_VERSION }}).
commit-message: 'chore(prisma): upgrade prisma to v${{ steps.publish.outputs.PRISMA_VERSION }}'
token: ${{ secrets.GH_TOKEN }}
- name: Enable auto-squash
if: ${{ steps.pr.outputs.pull-request-number }}
run: gh pr merge --auto --squash "${{ steps.pr.outputs.pull-request-number }}"
env:
PR_URL: ${{ github.event.pull_request.html_url }}
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}