We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 572236c commit b54b709Copy full SHA for b54b709
1 file changed
.github/workflows/format-app.yml
@@ -0,0 +1,33 @@
1
+name: Format App
2
+
3
+on:
4
+ push:
5
+ branches: [master, develop]
6
7
+jobs:
8
+ format:
9
+ runs-on: ubuntu-latest
10
+ steps:
11
+ - name: Checkout code
12
+ uses: actions/checkout@v4
13
+ with:
14
+ token: ${{ secrets.GITHUB_TOKEN }}
15
16
+ - name: Set up Python
17
+ uses: actions/setup-python@v5
18
19
+ python-version: '3.9'
20
21
+ - name: Install ruff
22
+ run: pip install ruff
23
24
+ - name: Run ruff format
25
+ run: ruff format packet
26
27
+ - name: Commit and push changes
28
+ run: |
29
+ git config --global user.name "github-actions[bot]"
30
+ git config --global user.email "github-actions[bot]@users.noreply.github.com"
31
+ git add .
32
+ git diff --cached --quiet || git commit -m "Auto-format code with ruff"
33
+ git push
0 commit comments