`set lists` tracking issue
- Dominant language
- Rust
- Stars
- 35.8k
- Forks
- 846
- Avg merge
- 27m
- Merged PRs (30d)
- 3
Description
When `set lists` is enabled, values may be list of strings, as opposed to strings.
This enables a number of nice features, for example, with `set list`, `quote()` applies to each individual argument:
```just
foo *args:
echo {{ quote(args) }}
```
So `foo a 'b c'` will print `'a' 'b c'`, instead of `'a b c'`.
`set lists` is unstable, both because it's a huge change, and because there are many contexts, mainly the built-in functions, where the ideal behavior of lists is still undecided. Currently, `join_list()` must be used wherever lists are used in contexts expecting a string.
## open questions
- Should we provide `TRUE` and `FALSE` constants?
- Is `show()` the right name for the list formatting function?
- Should exporting `[]` set the environment variable to `""` or skip setting it?
- Should `a + b` where `a` or `b` is `[]` be identity?
## todo
- Write more comprehensive docs, including why lists
- Update built-in functions to work with lists
- `for` expression or list comprehension that evaluates to lists
- List indexing and slicing
- Argument options can be allowed to repeat
- `*` for cartesian product
- #1990
- #2854
## done
- #3362
- #3372
- #3374
- #3375
- #2458
- #1988
- #558
- #3378
- #3380
- #1889
- #3381
- #3382
- #3383
- #3384
- #3258
- #3387
- #2411
- #2562
- #3336
- #2379
- #3389
- #3391
- #3398
- #3399
- #3402
- #3401
- #2002
- #3405
- #3406
- #3407
- #3412
- #3414
- #3415
- #3416
- #1350
- #3420
- #3418
- #3421
- #3427
Contributor guide
Assessment
This issue has not been assessed yet.