Skip to content

feat: add minimal database setup with SQLite and PostgreSQL support and CRUD operations example #40

feat: add minimal database setup with SQLite and PostgreSQL support and CRUD operations example

feat: add minimal database setup with SQLite and PostgreSQL support and CRUD operations example #40

Workflow file for this run

name: Lint and format
on:
pull_request:
branches:
- main
jobs:
check_if_branch_is_ahead_of_main:
runs-on: ubuntu-latest
steps:
- name: Git checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Check if branch is ahead of main
run: |
if ! git merge-base --is-ancestor origin/main ${{ github.event.pull_request.head.sha }};
then echo "This branch is not up to date with main";
exit 1; fi
test:
needs: check_if_branch_is_ahead_of_main
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.ref }}
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Changed files
id: changed_files
uses: tj-actions/changed-files@v44
- uses: pre-commit/action@v3.0.1
with:
extra_args: --files ${{ steps.changed_files.outputs.all_changed_files }}