(running over the previous version)
- It is developed with PureScript
0.15.9
and spago0.21.0
, but now I have updated tospago.yaml
, but still includespago.dhall
"just in case"; - I also drafted a
flake.nix
fornix
packaging and running:- It is not yet isolated with
node_packages
, and current CLI interface a.k.a. TUI requireschjj/blessed
library fromnpm
; - It works on my M1 Pro machine :D;
- With
purescript-overlay
it allows to select compiler andspago
, andspago build
and all the commands below should work there in theory; nix develop
works, where you can dospago build
andspago run
;nix build
works;nix run
is not yet working, something with the terminal output;
- It is not yet isolated with
nix run github:shamansir/noodle --extra-experimental-features nix-command --extra-experimental-features flakes
nix shell
should worknix build
also should work
- Latest
spago
should work (0.93.42
for the moment)- However it is developed with
spago
v0.21.0
- However it is developed with
purs
compilerv0.15.9
, it is not yet updated/checked on the latest version;npm install
is needed;
From starter toolkit:
sh ./run-cli.sh -t starter
sh ./run-cli.sh -f ./ndf/starter.v0.1.ndf
Will rewrite previous node definitions if they intersect
sh ./run-cli.sh -t starter -f ./ndf/starter.v0.1.ndf
Generate code for starter toolkit with purescript-codegen
using the given definition file
sh ./run-cli.sh -g ./ndf/starter.v0.1.ndf -t starter
By defaul the generated code will be located in ./src/Demo/_Gen/Starter
directory (./src/Demo/_Gen/<TOOLKIT-NAME>
). This could cause having double modules, though, and so fail to compile/start, since generated modules for toolkit could have the exact same name as the toolkit sources already provided in the repository, or just the sources that were generated before current run. In this case ensure that you don't need the previous sources at this location or have them commited to version control, and delete the target directory before generating new ones.
Also, you could specify output directory manually:
sh ./run-cli.sh -g ./ndf/starter.v0.1.ndf -t starter -o ~/Temp/_Codegen
Notice that toolkit name will be appended to the path automatically, you don't need to specify it
Command bar is called by <TAB>
key and currently supports these kinds of NDF
commands:
<family-name>
: spawn a node of given family:: <inlets-spec> => <outlets-spec>
: spawn a node of given shape, some examples::: <> => <>
: no inlets and no outlets:: <a:Number -> b:Number -> c:Number> => <>
: three inlets of given names and types:: <a -> b -> c> => <>
: just three inlets:: <r:Number -> g:Number -> b:Number> => <color:Color>
: three inlets of given names and types + one outlet of given name and type:: <r:Number -> g:Number -> b:Number> => <color:Color {c/ff0000}>
: three inlets of given names and types + one outlet of given name and type and default value:: <tuple> => <fst -> snd>
: one inlet and two outlets
sh ./run-cli.sh --help
sh ./test.sh
sh ./run-cli.sh --palette-test
: Test how color palette is visible in your terminal;sh ./run-cli.sh --cli-demo
: Test ifchjj/blessed
interface works;