Bobinas P4G
  • Login
  • Public

    • Public
    • Groups
    • Popular
    • People

Conversation

Notices

  1. nytpu (nytpu@tilde.zone)'s status on Sunday, 26-Dec-2021 12:18:03 UTC nytpu nytpu

    Okay Scheme is way too fucky wucky to make actually usable CLI utilities that actually support options and flags so fuck it I'm going for C and also not bothering to work on this project until after Christmas because now I'm too annoyed

    In conversation Sunday, 26-Dec-2021 12:18:03 UTC from tilde.zone permalink
    • Aligator (aligator@mastodon.social)'s status on Sunday, 26-Dec-2021 12:17:44 UTC Aligator Aligator
      in reply to
      • tychosoft
      • Be

      @tychosoft
      Actually I like the way go does it. And kubectl, docker, ... are all built with it and have a very nice cli.

      But thats only my opinion. In the end every one should use what he/she likes to use :-)

      @nytpu @be

      In conversation Sunday, 26-Dec-2021 12:17:44 UTC permalink
    • tychosoft (tychosoft@fosstodon.org)'s status on Sunday, 26-Dec-2021 12:18:02 UTC tychosoft tychosoft
      in reply to
      • Be

      @nytpu I will say, for cli argument parsing, #rust has an extremely simple and compact macro facility with lots of capabilities to describe flags, arguments, sub-commands, etc. #golang has a surprisingly awful "flags" package for this, I feel it is even worse than C getopt, while some third party libraries try to build on top of this misery to try offering something at least a bit more usable. For cli utilities, I would choose rust even if its miserable for some other things.

      @be

      In conversation Sunday, 26-Dec-2021 12:18:02 UTC permalink
    • muesli (fribbledom@mastodon.social)'s status on Sunday, 26-Dec-2021 12:18:17 UTC muesli muesli
      in reply to
      • tychosoft
      • Be
      • Aligator

      @tychosoft @aligator @nytpu @be

      The stdlib doesn't need to cover everything. These things exist: https://github.com/alexflint/go-arg

      In conversation Sunday, 26-Dec-2021 12:18:17 UTC permalink

      Attachments

      1. GitHub - alexflint/go-arg: Struct-based argument parsing in Go
        Struct-based argument parsing in Go. Contribute to alexflint/go-arg development by creating an account on GitHub.
    • tychosoft (tychosoft@fosstodon.org)'s status on Sunday, 26-Dec-2021 12:18:20 UTC tychosoft tychosoft
      in reply to
      • Be
      • Aligator

      @aligator @nytpu @be I think they use pflags, which is one of the more common extensions to flags. I think the real missed opportunity, though, would have been parsing cli flag directly with a tagged structure (``) instead. That would have been very cool.

      In conversation Sunday, 26-Dec-2021 12:18:20 UTC permalink

Feeds

  • Activity Streams
  • RSS 2.0
  • Atom
  • Help
  • About
  • FAQ
  • Privacy
  • Source
  • Version
  • Contact

Bobinas P4G is a social network. It runs on GNU social, version 2.0.1-beta0, available under the GNU Affero General Public License.

Creative Commons Attribution 3.0 All Bobinas P4G content and data are available under the Creative Commons Attribution 3.0 license.