From e576d9938a2e574e93d2436fee216df9c0628c0d Mon Sep 17 00:00:00 2001 From: Sigmanificient Date: Wed, 3 Dec 2025 17:26:32 +0100 Subject: [PATCH 1/2] ci: list all edited files --- .github/workflows/build.yml | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 .github/workflows/build.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 00000000..9cd602b9 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,27 @@ +name: Build Matrix + +on: + pull_request: + types: [opened, synchronize, reopened] + workflow_dispatch: +jobs: + generate-matrix: + runs-on: ubuntu-latest + outputs: + matrix: ${{ steps.set-matrix.outputs.matrix }} + steps: + - uses: actions/checkout@v5 + with: + fetch-depth: 0 + + - name: Get changed files + id: changed-files + uses: tj-actions/changed-files@v47 + + - name: List all changed files + env: + ALL_CHANGED_FILES: ${{ steps.changed-files.outputs.all_changed_files }} + run: | + for file in ${ALL_CHANGED_FILES}; do + echo "$file was changed" + done From a71d84b82b52c6dd752eac8197e5464d327e3b10 Mon Sep 17 00:00:00 2001 From: Sigmanificient Date: Wed, 3 Dec 2025 18:11:49 +0100 Subject: [PATCH 2/2] cabal-extract: remove rev-dep filter --- cabal-extract/Main.hs | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/cabal-extract/Main.hs b/cabal-extract/Main.hs index 36cbfb55..6d9a7169 100644 --- a/cabal-extract/Main.hs +++ b/cabal-extract/Main.hs @@ -34,7 +34,6 @@ import System.Directory getCurrentDirectory, listDirectory, ) -import System.Environment (getArgs) import System.FilePath ( takeExtension, takeFileName, @@ -152,15 +151,11 @@ removeExternalDeps = map removeExt } main :: IO () -main = do - args <- getArgs - - allCabals <- getCurrentDirectory >>= findCabalFiles >>= extractFlatDepTree - allTargets <- mapM findCabalFiles args >>= extractFlatDepTree . concat - - filter (\c -> ciName c `elem` map ciName allTargets) allCabals - & encode - & BL.putStrLn +main = + getCurrentDirectory + >>= findCabalFiles + >>= extractFlatDepTree + >>= BL.putStrLn . encode where extractFlatDepTree x = mapM (readGenericPackageDescription Verbosity.deafening) x