Stream: show and tell

Topic: wled-cli


view this post on Zulip Dan (Jan 10 2024 at 01:33):

Dead simple cli for toggling WLED.

Nothing special that can't be handled by bash/fish + jq :grinning_face_with_smiling_eyes: but heard recently that Roc is close to start making named releases and considered it as a sign to start using it (instead of just following news).

https://github.com/dector/wled-cli

view this post on Zulip Hannes Nevalainen (Jan 10 2024 at 02:12):

Nice! :)
I would maybe do some error handling with the Result type , for instance when parsing the arguments.

Also there is multiline strings so you do not have to do the Str.joinWith thingy:

printHelp =
    str =
        """
        \(appName) v\(appVersion)
        Usage:
        \(appName) <command> [<arguments>]

        Commands:
          toggle <ip>    Toggle WLED instance power
          version        Print current version number and exit
          help           Print usage info and exit
        """
    Stdout.line str

view this post on Zulip Dan (Jan 10 2024 at 09:44):

Hannes Nevalainenyeah, will do proper error handling for sure. Thanks for other suggestions as well!


Last updated: Jul 06 2025 at 12:14 UTC