Skip to content

Commit

Permalink
autoformat cabal file (#1769)
Browse files Browse the repository at this point in the history
Closes #1709.
  • Loading branch information
kostmo authored Feb 19, 2024
1 parent 9253b0e commit e851f44
Show file tree
Hide file tree
Showing 3 changed files with 870 additions and 773 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/normalize-cabal.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Normalize cabal file formatting
on:
push:
paths:
- '**.hs'
- '**.cabal'
branches:
- main
pull_request:
paths:
- '**.hs'
- '**.cabal'
branches:
- main
jobs:
gild:
name: Normalize cabal
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- uses: tfausak/cabal-gild-setup-action@v1
with:
version: 0.3.0.1
- run: cabal-gild --input swarm.cabal --mode check
7 changes: 7 additions & 0 deletions scripts/normalize-cabal.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/bin/bash -ex

SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
cd $SCRIPT_DIR/..

CABAL_FILE=swarm.cabal
cabal-gild --input $CABAL_FILE --output $CABAL_FILE --mode format
Loading

0 comments on commit e851f44

Please sign in to comment.