Closed wolfadex closed 3 months ago
Alternatively:
--types
: a list of (cmd | task | cmdrisky | taskrisky)
--packages
: a list of (elm/http | lamdera/program-test | dillonkearns/elm-pages | avh4/elm-program-test | andrewMacmurray/elm-concurrent-task)
- if empty use [elm/http]
Alternatively², for --effect-types
:
cmd
cmd-risky
task
task-risky
dillonkearns/elm-pages [this produces BackendTask]
lamdera/program-test [this produces both Command and Effect.Task]
avh4/elm-program-test
Alternatively³:
--effect-types
: a list of [package].[type]
, where type
defaults to "all of them" and package
defaults to elm/http
.
So cmd
is elm/http.cmd
, dillonkearns/elm-pages
is everything from elm-pages
, lamdera/program-test.task
are just the tasks from lamdera/program-test
, etc
This is retrocompatible and flexible yet simply usable
I'm liking option 3 the most right now. It's the most flexible & most explicit, and explicit feels the most Elm-like.
The only hard part is writing a nice help message for it :D
those are verbose, but also more clear as to where they're coming from, especially if we added say
avh4/elm-program-test
because it'd be more difficult to tell that apart from the Lamdera one.Would love to get your thoughts
_Originally posted by @wolfadex in https://github.com/wolfadex/elm-open-api-cli/pull/108#discussion_r1672625207_