Automatically run nightly rustfmt #95
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: Automatically run nightly rustfmt | |
on: | |
schedule: | |
- cron: "30 3 * * 1" # runs weekly on Monday at 3:30 UTC | |
workflow_dispatch: | |
jobs: | |
rustfmt: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4.2.1 | |
- uses: actions-rs/toolchain@v1 | |
with: | |
profile: minimal | |
toolchain: nightly | |
override: true | |
components: rustfmt | |
- name: Format | |
run: | | |
cargo fmt -- --config imports_granularity=Crate --config group_imports=StdExternalCrate | |
- name: Create pull request | |
uses: peter-evans/create-pull-request@v7 | |
with: | |
token: ${{ secrets.GH_TOKEN_FOR_UPDATES }} | |
commit-message: Run nightly rustfmt | |
title: "[Automated] Run nightly rustfmt" | |
branch: automated/rustfmt | |
body: > | |
This is an auto-generated PR running nightly rustfmt |