Skip to content

Commit 183ad05

Browse files
Prep repo (#37)
* Update CI node/actions version; add purs-tidy * Format code via purs-tidy * Add entry
1 parent 9d126d9 commit 183ad05

File tree

3 files changed

+28
-19
lines changed

3 files changed

+28
-19
lines changed

.github/workflows/ci.yml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,16 @@ jobs:
1010
build:
1111
runs-on: ubuntu-latest
1212
steps:
13-
- uses: actions/checkout@v2
13+
- uses: actions/checkout@v3
1414

1515
- uses: purescript-contrib/setup-purescript@main
1616
with:
1717
purescript: "unstable"
18+
purs-tidy: "latest"
1819

19-
- uses: actions/setup-node@v2
20+
- uses: actions/setup-node@v3
2021
with:
21-
node-version: "14"
22+
node-version: "lts/*"
2223

2324
- name: Install dependencies
2425
run: |
@@ -33,3 +34,8 @@ jobs:
3334
run: |
3435
bower install
3536
npm run-script test --if-present
37+
38+
- name: Check Formatting
39+
if: runner.os == 'Linux'
40+
run: |
41+
npx purs-tidy check src

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@ New features:
1111
Bugfixes:
1212

1313
Other improvements:
14+
- Bumped CI's node version to `lts/*` (#37 by @JordanMartinez)
15+
- Updated CI `actions/checkout` and `actions/setup-nodee` to `v3` (#37 by @JordanMartinez)
16+
- Format codebase & enforce formatting in CI via purs-tidy (#37 by @JordanMartinez)
1417

1518
## [v10.0.0](https://github.com/purescript-node/purescript-node-process/releases/tag/v10.0.0) - 2022-04-29
1619

src/Node/Platform.purs

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -18,36 +18,36 @@ data Platform
1818

1919
-- | The String representation for a platform, recognised by Node.js.
2020
toString :: Platform -> String
21-
toString AIX = "aix"
22-
toString Darwin = "darwin"
21+
toString AIX = "aix"
22+
toString Darwin = "darwin"
2323
toString FreeBSD = "freebsd"
24-
toString Linux = "linux"
24+
toString Linux = "linux"
2525
toString OpenBSD = "openbsd"
26-
toString SunOS = "sunos"
27-
toString Win32 = "win32"
26+
toString SunOS = "sunos"
27+
toString Win32 = "win32"
2828
toString Android = "android"
2929

3030
-- | Attempt to parse a `Platform` value from a string, in the format returned
3131
-- | by Node.js' `process.platform`.
3232
fromString :: String -> Maybe Platform
33-
fromString "aix" = Just AIX
34-
fromString "darwin" = Just Darwin
33+
fromString "aix" = Just AIX
34+
fromString "darwin" = Just Darwin
3535
fromString "freebsd" = Just FreeBSD
36-
fromString "linux" = Just Linux
36+
fromString "linux" = Just Linux
3737
fromString "openbsd" = Just OpenBSD
38-
fromString "sunos" = Just SunOS
39-
fromString "win32" = Just Win32
38+
fromString "sunos" = Just SunOS
39+
fromString "win32" = Just Win32
4040
fromString "android" = Just Android
41-
fromString _ = Nothing
41+
fromString _ = Nothing
4242

4343
instance showPlatform :: Show Platform where
44-
show AIX = "AIX"
45-
show Darwin = "Darwin"
44+
show AIX = "AIX"
45+
show Darwin = "Darwin"
4646
show FreeBSD = "FreeBSD"
47-
show Linux = "Linux"
47+
show Linux = "Linux"
4848
show OpenBSD = "OpenBSD"
49-
show SunOS = "SunOS"
50-
show Win32 = "Win32"
49+
show SunOS = "SunOS"
50+
show Win32 = "Win32"
5151
show Android = "Android"
5252

5353
derive instance eqPlatform :: Eq Platform

0 commit comments

Comments
 (0)