Skip to content

sqlx prepare

sqlx prepare #79

Workflow file for this run

name: Rustfmt
# Runs `cargo fmt` whenever code is pushed or pr'd into master.
on:
push:
branches:
- master
pull_request:
branches:
- master
types:
- closed
jobs:
format:
name: Rustfmt
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
components: rustfmt
- run: rustup component add rustfmt
- uses: actions-rs/cargo@v1
with:
command: fmt
args: --all
- name: Commit files # only runs if something actually changed
run: |
if [[ -n "$(git status -s)" ]]; then
git config --local user.email "[email protected]"
git config --local user.name "GitHub Action"
git commit -m "CI: Automatic Rustfmt" -a
fi
- name: Push changes
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}