From 4ee09514f31fc240846042c75b355f24e3562d3a Mon Sep 17 00:00:00 2001 From: Thomas Honeyman Date: Wed, 4 Nov 2026 03:45:26 +0000 Subject: [PATCH 1/2] Migrate to Spago and update CI --- .github/workflows/ci.yml | 14 ++++++++------ .gitignore | 1 + bower.json | 20 -------------------- package.json | 2 +- packages.dhall | 6 ------ spago.dhall | 7 ------- spago.yaml | 20 ++++++++++++++++++++ test.dhall | 13 ------------- 8 files changed, 30 insertions(+), 53 deletions(-) delete mode 100644 bower.json delete mode 100644 packages.dhall delete mode 100644 spago.dhall create mode 100644 spago.yaml delete mode 100644 test.dhall diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f1edb87..6249452 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -12,25 +12,27 @@ jobs: steps: - uses: actions/checkout@v2 - - uses: purescript-contrib/setup-purescript@main - - uses: actions/setup-node@v2 with: - node-version: "14" + node-version: "22" + + - uses: purescript-contrib/setup-purescript@main + with: + spago: "1.0.5" - name: Cache PureScript dependencies uses: actions/cache@v2 - # This cache uses the .dhall files to know when it should reinstall + # This cache uses the spago.yaml files to know when it should reinstall # and rebuild packages. It caches both the installed packages from # the `.spago` directory and compilation artifacts from the `output` # directory. When restored the compiler will rebuild any files that # have changed. If you do not want to cache compiled output, remove # the `output` path. with: - key: ${{ runner.os }}-spago-${{ hashFiles('**/*.dhall') }} + key: ${{ runner.os }}-spago-${{ hashFiles('**/spago.yaml') }} path: | .spago output - run: spago build - - run: spago -x test.dhall test + - run: spago test diff --git a/.gitignore b/.gitignore index 30efe19..9f9d1a7 100644 --- a/.gitignore +++ b/.gitignore @@ -8,3 +8,4 @@ /.purs* /.psa* /.spago +/spago.lock diff --git a/bower.json b/bower.json deleted file mode 100644 index 5567198..0000000 --- a/bower.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "name": "purescript-react-markdown", - "license": [ - "MIT-0" - ], - "repository": { - "type": "git", - "url": "https://github.com/rowtype-yoga/purescript-react-markdown.git" - }, - "ignore": [ - "**/.*", - "node_modules", - "bower_components", - "output" - ], - "dependencies": { - "purescript-prelude": "^v6.0.1", - "purescript-react-basic-hooks": "^v8.1.2" - } -} diff --git a/package.json b/package.json index 456216f..04ce236 100644 --- a/package.json +++ b/package.json @@ -7,7 +7,7 @@ "test": "test" }, "scripts": { - "test": "spago -x test.dhall test" + "test": "spago test" }, "keywords": [], "author": "", diff --git a/packages.dhall b/packages.dhall deleted file mode 100644 index 8d8d4ef..0000000 --- a/packages.dhall +++ /dev/null @@ -1,6 +0,0 @@ - -let upstream = - https://github.com/purescript/package-sets/releases/download/psc-0.15.4-20221212/packages.dhall - sha256:62ea94a2728dc4f0a47491c064776f402a8a1b3cf2d8a7ec83c96075d30bd590 - -in upstream diff --git a/spago.dhall b/spago.dhall deleted file mode 100644 index 9c7929d..0000000 --- a/spago.dhall +++ /dev/null @@ -1,7 +0,0 @@ -{ name = "react-markdown" -, dependencies = [ "prelude", "react-basic-hooks" ] -, packages = ./packages.dhall -, sources = [ "src/**/*.purs" ] -, license = "MIT-0" -, repository = "https://github.com/rowtype-yoga/purescript-react-markdown.git" -} diff --git a/spago.yaml b/spago.yaml new file mode 100644 index 0000000..2e065ee --- /dev/null +++ b/spago.yaml @@ -0,0 +1,20 @@ +package: + name: react-markdown + publish: + version: 0.1.1 + license: MIT-0 + location: + githubOwner: purescript-react + githubRepo: purescript-react-markdown + dependencies: + - prelude: ">=6.0.1 <7.0.0" + - react-basic-hooks: ">=8.1.2 <9.0.0" + test: + main: Test.Main + dependencies: + - aff: ">=7.1.0 <9.0.0" + - console: ">=6.0.0 <7.0.0" + - effect: ">=4.0.0 <5.0.0" + - spec: ">=7.1.0 <9.0.0" + - spec-discovery: ">=8.0.1 <9.0.0" +workspace: {} diff --git a/test.dhall b/test.dhall deleted file mode 100644 index e8b7995..0000000 --- a/test.dhall +++ /dev/null @@ -1,13 +0,0 @@ -let conf = ./spago.dhall - -in conf - // { sources = conf.sources # [ "test/**/*.purs" ] - , dependencies = - conf.dependencies - # [ "aff" - , "console" - , "effect" - , "spec" - , "spec-discovery" - ] - } From 1f5847c57a54a9dcf64a8f97f54e06b47d832c80 Mon Sep 17 00:00:00 2001 From: Thomas Honeyman Date: Thu, 5 Nov 2026 01:35:27 +0000 Subject: [PATCH 2/2] Update retired cache action to v4 --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6249452..f9878a7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -21,7 +21,7 @@ jobs: spago: "1.0.5" - name: Cache PureScript dependencies - uses: actions/cache@v2 + uses: actions/cache@v4 # This cache uses the spago.yaml files to know when it should reinstall # and rebuild packages. It caches both the installed packages from # the `.spago` directory and compilation artifacts from the `output`