Commit graph

755 commits

Author SHA1 Message Date
Agus Zubiaga
c1a82ae59b
Merge pull request #7199 from roc-lang/fix-imports-in-expect-7025 2024-11-06 07:56:21 -03:00
Agus Zubiaga
0dedab1725
Fix imports in expects #7025 2024-11-05 19:13:29 -03:00
Agus Zubiaga
6c505a4dc8
Add test for fixed issue 7116 2024-11-05 18:12:56 -03:00
Agus Zubiaga
625a5425f4
Unify import params on copied variable 2024-11-05 18:10:01 -03:00
Sam Mohr
ca762127e5
Fix formatting and clippy errors 2024-10-24 23:11:20 -07:00
Jasper Woudenberg
ad555297cf
Set argv[0] to .roc file passed to 'roc run'
When we run `roc run <file>` or `roc <file>` then Roc will compile a
binary and run it. Before this commit we would set the path to the
compiled binary as argv[0]. This commit changes the behavior to make
argv[0] in the binary correspond to the roc file being ran.

This benefits the use of roc scripts that make use of a shebang:

    #!/usr/bin/env roc

With this change such scripts will be able to read the path to
themselves out of ARGV. This trick is commonly used for instance by bash
scripts in order to access files relative to the script itself.
2024-10-21 21:54:46 +02:00
Anton-4
837dc7b7cc
Merge pull request #7154 from DavidEdwards1/allow-check-on-markdown
Initial Sketch of roc check on Markdown
2024-10-15 13:54:09 +02:00
Anton-4
734a4e4504
clean up dbg
Signed-off-by: Anton-4 <17049058+Anton-4@users.noreply.github.com>
2024-10-15 12:54:52 +02:00
Anton-4
e73484d282
improve names
Signed-off-by: Anton-4 <17049058+Anton-4@users.noreply.github.com>
2024-10-15 12:53:56 +02:00
David Edwards
94ad57dcfa
Read file line by line rather than all at once 2024-10-13 21:33:41 +01:00
David Edwards
13ffa9b9db
Initial Sketch of roc check on Markdown
This commit alters `roc check` to be able to run on Markdown files. The overall flow is:
 - check if the file has a `.md` extension
  - if it does extract any fenced code blocks marked as Roc
  - write those blocks to temp files
  - run `roc check` sequentially on every temp file
  - print out the results of `roc check`
  - exit early if any individual `roc check` has non-zero exit status
 - if the file does not have `.md` extension proceed as before
2024-10-09 21:13:45 +01:00
Brendan Hansknecht
21e370f41f
minor formatting fixes 2024-10-07 21:16:30 -07:00
Brendan Hansknecht
9da9c08015
make the test more robust and actually run it 2024-10-07 21:16:30 -07:00
Brendan Hansknecht
3c232446d9
add a test for multiple expose and fix naming 2024-10-07 21:16:30 -07:00
Brendan Hansknecht
c61b7bf2a6
Remove requires type from the provides field 2024-10-07 21:16:30 -07:00
Omar Jatoi
3f318e2235
update existing calls to roc_cache_dir()
using `roc_cache_packages_dir()` instead, which will return "~/.cache/roc/packages", which was the existing functionality, but `roc_cache_dir()` will now return "~/.cache/roc"
2024-10-03 12:52:52 -04:00
Hannes
058ef106af Add commit information to roc versions built from source 2024-09-25 21:12:46 +08:00
Agus Zubiaga
3eadc03e28
Add failing test for multiline params 2024-09-20 16:19:56 -03:00
Aurélien Geron
b57258f5cb
Remove a couple remaining references to pf.Task 2024-09-11 15:39:26 +12:00
Sam Mohr
aadc74a37b
Merge branch 'main' into repl-no-color-no-header-flags 2024-09-06 15:52:18 -07:00
Anton-4
f89f2e8ea7
fix #6987
Signed-off-by: Anton-4 <17049058+Anton-4@users.noreply.github.com>
2024-09-03 20:43:25 +02:00
Agus Zubiaga
e4079ccb11
Add module_params_pass_task test 2024-09-01 19:18:07 -03:00
Anton-4
e7a44430fd
update to basic cli 15 2024-08-31 14:30:07 +02:00
Anton-4
3c679f6338
Merge branch 'main' into lower-module-params 2024-08-30 16:29:46 +02:00
Sam Mohr
3f866d93ae
Ignore false-interpreter test, unrelated issue 2024-08-29 19:50:03 -07:00
jamin-eisenberg
d9db14c3d7
Make whitespace uniform 2024-08-28 18:15:24 -04:00
jamin-eisenberg
7429f8a970
Initial attempt (failing tests?) 2024-08-28 18:15:23 -04:00
Anton-4
7938e4bdc8
basic-cli 0.15, test fixes 2024-08-28 18:39:15 +02:00
Anton-4
ca7d1cb3fa
Revert "Avoid defining unsized platform Tasks"
This reverts commit d3732b4440.
2024-08-28 16:37:01 +02:00
Agus Zubiaga
287a8fa2e7
Merge branch 'main' into lower-module-params 2024-08-28 08:50:40 -03:00
Agus Zubiaga
d033057a58
Hide params from annotation type mismatches 2024-08-27 19:06:31 -03:00
Agus Zubiaga
a4f4d00ff0
Add unexpected fn params test case 2024-08-27 17:24:13 -03:00
Agus Zubiaga
dd78b8e25b
Add TOO FEW ARGS test case for params 2024-08-27 17:08:55 -03:00
Agus Zubiaga
121a087328
Handle TOO MANY ARGS error for value defs 2024-08-27 17:04:39 -03:00
Agus Zubiaga
658c6963c5
Remove param arguments from TOO MANY ARGS error 2024-08-27 16:08:26 -03:00
Agus Zubiaga
49a6b1bfba
Capture whole params record when needed 2024-08-27 11:20:59 -03:00
Agus Zubiaga
b70d48fd33
Handle simple params extended def alias 2024-08-27 01:32:08 -03:00
Agus Zubiaga
36df43fadc
Handle simple aliased fn in params value def 2024-08-27 01:27:54 -03:00
Agus Zubiaga
3c6a2f11d7
Capture params in lowered passed fns from importer side 2024-08-27 00:02:26 -03:00
Agus Zubiaga
b667753a32
Capture import params def 2024-08-26 23:31:42 -03:00
Agus Zubiaga
0bf833dae9
Lower passed imported functions 2024-08-26 23:21:18 -03:00
Sam Mohr
d3732b4440
Avoid defining unsized platform Tasks 2024-08-26 15:04:31 -07:00
Sam Mohr
79cfcb072b
Pluralize PlatformTasks module 2024-08-26 00:05:09 -07:00
Luke Boswell
10241b3f98
Merge remote-tracking branch 'remote/main' into builtin-task 2024-08-24 09:53:08 +10:00
Anton-4
44b8abdead
update to basic-cli 0.14 2024-08-23 15:50:05 +02:00
Agus Zubiaga
be4ebfe901
Lower passed top-level functions in a module with params 2024-08-21 20:07:08 -03:00
Sam Mohr
12df3a04de
Merge attempt 2024-08-19 23:34:05 -07:00
Sam Mohr
7c7485bb04
Merge pull request #7005 from smores56/deprecate-backpassing
Deprecate backpassing to prepare for eventual removal
2024-08-18 08:08:29 -04:00
Agus Zubiaga
50efed6612
Add dynamic param test 2024-08-17 16:35:48 -03:00
Agus Zubiaga
50887e6265
Capture params in nested defs 2024-08-17 16:13:44 -03:00