Skip to content

JohnGurin/exercism-purescript-setup

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Exercism Purescript track setup

https://exercism.org/tracks/purescript

The goal

  • Uses local spago and purescript libraries.
  • Prevents the downloading of equal packages in every exercise folder.

The usage

  • Requirements: exercism-cli https://exercism.org/cli-walkthrough.
  • Install npm dependencies npm i
  • Add an exercise with npm run addex <exercise> (for example, pangram)
  • Go in the exercise folder cd exercises/<exercise>
  • Run test npm test

Npm scripts

setup

  • setup-dirs - creates ./.spago and ./output folders
  • setup-link - links <exercism-workspace>/purescript to ./exercises

exercise

  • addex <exercise> consists of other two npm scripts:
  • ex-download <exercise> - downloads the exercise into exericsm workspace folder (in this case, <exercism-workspace>/purescript/<exercise>)
  • ex-link <exercise> - links ./exercises/<exercise>/{.spago,output} to ./.spago and ./output folders.

vscode

  • vscode-workspace creates (if not exists) vscode workspace file in ./.vscode/ with ./exercises/* sub-folders, updates settings.purescript.pursExe to ./node_modules/.bin/purs.

idea

  • open the . folder
Typical folders structure
.
├── exercism-workspace
│   └── purescript (1)
|       └── pangram
└── exercism-purescript-setup
    ├── .spago (2)
    ├── output (3)
    ├── node_modules
    └── exercises (-> 1)
        └── pangram
            ├── .exercism
            ├── .spago (-> 2)
            ├── output (-> 3)
            ├── src
            └── test

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors