1
1
mirror of https://github.com/anoma/juvix.git synced 2025-01-07 16:22:14 +03:00
juvix/app/Commands
Jan Mas Rovira 021f183d33
Run Nockma in an Anoma node (#3128)
# Changes
1. Adds a new command `juvix dev anoma node`. This command runs the
anoma node.
2. Adds a flag `--anoma-dir` to `juvix dev nockma run`. When given, it
must point to the anoma clone. Then, it will run the nockma code in the
anoma node and report the result (with no traces).

# Prerequisites
1. An anoma clone at some specific commit. 
   ```
   git clone git@github.com:anoma/anoma.git
   cd anoma
   git checkout 98e3660b91cd55f1d9424dcff9420425ae98f5f8
   
   # build anoma
   mix deps.get
   mix escript.install hex protobuf
   mix compile

   # build the client
   mix do --app anoma_client escript.build
   ```
2. The `mix` command (elixir).
3. The [`grpcurl`](https://github.com/fullstorydev/grpcurl) command. To
install a single binary in `~/.local/bin` you can run:
   ```
curl -sSL
"https://github.com/fullstorydev/grpcurl/releases/download/v1.9.1/grpcurl_1.9.1_linux_x86_64.tar.gz"
| tar -xz -C ~/.local/bin --no-wildcards grpcurl
   ```

# Testing
I've not included any test. It can be tested locally like this:
```
cd juvix/tests/Anoma/Compilation/positive
juvix compile anoma test001.juvix
echo 20 > args.debug.nockma
juvix dev nockma run --anoma-dir ~/projects/anoma test001.nockma --args args.debug.nockma
2024-10-29 17:32:59 +01:00
..
Clean Use Package.juvix in the global project (#2499) 2023-11-06 11:49:43 +00:00
Compile Run Nockma in an Anoma node (#3128) 2024-10-29 17:32:59 +01:00
Dependencies Logger (#2908) 2024-07-22 17:14:37 +02:00
Dev Run Nockma in an Anoma node (#3128) 2024-10-29 17:32:59 +01:00
Doctor Global offline flag (#2335) 2023-09-05 17:11:17 +02:00
Eval Make compile targets a subcommand instead of a flag (#2700) 2024-04-09 13:29:07 +02:00
Extra Compile-time configuration (#3102) 2024-10-16 11:47:23 +02:00
Format Improve performance of formatting a project (#2863) 2024-07-01 18:05:24 +02:00
Html Improve css themes (#2921) 2024-08-01 18:32:03 +02:00
Init Add PackageDescription.Basic module Package variant (#2509) 2023-11-13 17:36:18 +00:00
Isabelle Translate function bodies to Isabelle/HOL (#2868) 2024-07-19 08:40:07 +01:00
Markdown Make compile targets a subcommand instead of a flag (#2700) 2024-04-09 13:29:07 +02:00
Repl Per-module compilation (#2468) 2023-12-30 20:15:35 +01:00
Typecheck Make compile targets a subcommand instead of a flag (#2700) 2024-04-09 13:29:07 +02:00
Base.hs juvix typecheck with no file argument typechecks the whole project (#2889) 2024-07-12 17:48:29 +02:00
Clean.hs Use Package.juvix in the global project (#2499) 2023-11-06 11:49:43 +00:00
Compile.hs Remove VampIR compile command and tests (#3104) 2024-10-16 15:03:14 +02:00
Dependencies.hs Logger (#2908) 2024-07-22 17:14:37 +02:00
Dev.hs Run Nockma in an Anoma node (#3128) 2024-10-29 17:32:59 +01:00
Doctor.hs Compile-time configuration (#3102) 2024-10-16 11:47:23 +02:00
Eval.hs Logger (#2908) 2024-07-22 17:14:37 +02:00
Format.hs Logger (#2908) 2024-07-22 17:14:37 +02:00
Html.hs Do not show progress log for juvix html (#2920) 2024-07-30 18:57:58 +02:00
Init.hs Logger (#2908) 2024-07-22 17:14:37 +02:00
Isabelle.hs Isabelle/HOL translation: comments (#2974) 2024-09-02 15:56:58 +02:00
Markdown.hs Logger (#2908) 2024-07-22 17:14:37 +02:00
Repl.hs Export Juvix source code to latex (#2917) 2024-08-05 11:28:19 +02:00
Typecheck.hs Improve compilation progress log (#2969) 2024-08-30 00:10:13 +02:00