Stream: show and tell

Topic: Roc ASCII


view this post on Zulip Hannes (May 03 2024 at 02:02):

https://github.com/Hasnep/roc-ascii

Most of the time it's best to support UTF-8, but sometimes you have data that is just ASCII and you can avoid some of the complexity of UTF-8, so I made a quick package with two types: an ASCII string and an ASCII character. See the docs for more info: https://hasnep.github.io/roc-ascii

view this post on Zulip Hannes (Feb 03 2025 at 12:10):

I've just released v0.3.0 of roc-ascii which supports Roc v0.0.0-alpha2 and changes the Ascii type from an opaque type to a plain List Char :)

view this post on Zulip Hannes (Aug 18 2026 at 02:37):

I've just released v0.4.0 v0.4.1 of roc-ascii which supports the new Roc compiler :)

view this post on Zulip Aurélien Geron (Aug 18 2026 at 03:37):

Awesome @Hannes ! I'll add it to the list of libraries available in the Exercism Roc track, since most exercises that manipulate text assume it's ASCII-only. However, it looks like there's currently no release file (.tar.zst)?

view this post on Zulip Hannes (Aug 18 2026 at 04:46):

Just having some technical difficulties with CI, will be ready soon!

view this post on Zulip Hannes (Aug 18 2026 at 06:01):

Okay, v0.4.1 has been released!

view this post on Zulip Aurélien Geron (Aug 18 2026 at 06:30):

@Hannes it looks like something's wrong with the release file, for some reason:

── ✗ package download failed ───────────────────────────────────────────────────────────────────────────────────────────

Failed to download and extract this package:

    https://github.com/Hasnep/roc-ascii/releases/download/v0.4.1/AnawhDawcVySaW3ywcvfUPuhbXfJK7jcwEHaMBAfVv2y.tar.zst

Error: FileNotFound.

── 1 error and 0 warnings ──────────────────────────────────────────────────────────────── bin/download-dependencies.roc

view this post on Zulip Hannes (Aug 18 2026 at 06:32):

Uhoh, I didn't test it :sweat_smile: let me have a look!

view this post on Zulip Aurélien Geron (Aug 18 2026 at 06:32):

Oh it looks like the roc bundle command was launched from the root directory instead of inside the src directory:

% tar xvf AnawhDawcVySaW3ywcvfUPuhbXfJK7jcwEHaMBAfVv2y.tar.zst
x src/main.roc
x src/Char.roc
x src/Utils.roc
x src/Ascii.roc

view this post on Zulip Hannes (Aug 18 2026 at 06:46):

Created an issue for this: https://github.com/roc-lang/roc/issues/10845

view this post on Zulip Luke Boswell (Aug 18 2026 at 06:47):

I think this is by design, you need to explicitly pass the files you want bundled. It doesn't auto find them like the old compiler

view this post on Zulip Luke Boswell (Aug 18 2026 at 06:48):

The design for packages and the targets is a little different. The goal is to give platform/package authors more flexibility and control.

view this post on Zulip Aurélien Geron (Aug 18 2026 at 06:49):

FYI, I just ran roc bundle main.roc inside the src directory, and the bundle contains all *.roc files in this directory (presumably because they're listed in main.roc).

view this post on Zulip Luke Boswell (Aug 18 2026 at 06:53):

Cool, I probably have outdated memory then

view this post on Zulip Richard Feldman (Aug 18 2026 at 12:16):

I do think we should auto-discover dependencies and include those

view this post on Zulip Richard Feldman (Aug 18 2026 at 12:17):

like if you include a .roc file which imports other files, we should bring all those in so your bundle isn't broken :sweat_smile:


Last updated: Sep 03 2026 at 15:16 UTC