Skip to content
  • Hjem
  • Seneste
  • Etiketter
  • Populære
  • Verden
  • Bruger
  • Grupper
Temaer
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Kollaps
FARVEL BIG TECH
  1. Forside
  2. Ikke-kategoriseret
  3. i feel like i've probably asked this before but has anyone written a fancy command line man page viewer to replace `man`?

i feel like i've probably asked this before but has anyone written a fancy command line man page viewer to replace `man`?

Planlagt Fastgjort Låst Flyttet Ikke-kategoriseret
49 Indlæg 34 Posters 44 Visninger
  • Ældste til nyeste
  • Nyeste til ældste
  • Most Votes
Svar
  • Svar som emne
Login for at svare
Denne tråd er blevet slettet. Kun brugere med emne behandlings privilegier kan se den.
  • b0rk@social.jvns.caB b0rk@social.jvns.ca

    i feel like i've probably asked this before but has anyone written a fancy command line man page viewer to replace `man`?

    (not emacs or vim)

    puppethead@ieji.deP This user is from outside of this forum
    puppethead@ieji.deP This user is from outside of this forum
    puppethead@ieji.de
    wrote sidst redigeret af
    #30

    @b0rk Maybe something like manx? It's for macOS but it is just a bash script so maybe it could be tweaked for other platforms.

    https://github.com/jakshin/manx

    1 Reply Last reply
    0
    • rjbs@social.semiotic.systemsR rjbs@social.semiotic.systems

      @b0rk Ugggggh if you find a good answer, please repost it with a bright red light. I think the biggest issue is that the roff format is too bankrupt, and we need better linking primitives, but… I might just be jaded.

      milo@types.plM This user is from outside of this forum
      milo@types.plM This user is from outside of this forum
      milo@types.pl
      wrote sidst redigeret af
      #31

      @rjbs @b0rk this was my first thought lol. roff is incredibly cursed

      1 Reply Last reply
      0
      • b0rk@social.jvns.caB b0rk@social.jvns.ca

        i feel like i've probably asked this before but has anyone written a fancy command line man page viewer to replace `man`?

        (not emacs or vim)

        nafmo@social.vivaldi.netN This user is from outside of this forum
        nafmo@social.vivaldi.netN This user is from outside of this forum
        nafmo@social.vivaldi.net
        wrote sidst redigeret af
        #32

        @b0rk Not replace, but this script opens in a PDF viewer:

        https://www.softwolves.com/wolfblog/2024/11/19/making-man-pages-easier-to-read/

        I did write a simple HTML man page render back at university (1997), I wonder if I still have the sources for that...

        1 Reply Last reply
        0
        • b0rk@social.jvns.caB b0rk@social.jvns.ca

          i feel like i've probably asked this before but has anyone written a fancy command line man page viewer to replace `man`?

          (not emacs or vim)

          literatesavant@mastodon.auL This user is from outside of this forum
          literatesavant@mastodon.auL This user is from outside of this forum
          literatesavant@mastodon.au
          wrote sidst redigeret af
          #33

          @b0rk tangent: I've been using Linux for 27 years but I'm still unclear on why sometimes typing "man 5 {command}" gives me a different and more detailed man page.

          literatesavant@mastodon.auL 1 Reply Last reply
          0
          • literatesavant@mastodon.auL literatesavant@mastodon.au

            @b0rk tangent: I've been using Linux for 27 years but I'm still unclear on why sometimes typing "man 5 {command}" gives me a different and more detailed man page.

            literatesavant@mastodon.auL This user is from outside of this forum
            literatesavant@mastodon.auL This user is from outside of this forum
            literatesavant@mastodon.au
            wrote sidst redigeret af
            #34

            @b0rk (now I know the answer)

            b0rk@social.jvns.caB 1 Reply Last reply
            0
            • literatesavant@mastodon.auL literatesavant@mastodon.au

              @b0rk (now I know the answer)

              b0rk@social.jvns.caB This user is from outside of this forum
              b0rk@social.jvns.caB This user is from outside of this forum
              b0rk@social.jvns.ca
              wrote sidst redigeret af
              #35

              @literatesavant what's the answer?

              literatesavant@mastodon.auL 1 Reply Last reply
              0
              • b0rk@social.jvns.caB b0rk@social.jvns.ca

                @doekman it's so nice! my dream is that somehow someone has made something like that for the terminal

                doekman@mastodon.nlD This user is from outside of this forum
                doekman@mastodon.nlD This user is from outside of this forum
                doekman@mastodon.nl
                wrote sidst redigeret af
                #36

                @b0rk It is, right? FWIW: sometimes I use this function to open a man-page: it opens a new terminal window.

                function yman() { open "x-man-page://$1" ; }

                1 Reply Last reply
                0
                • b0rk@social.jvns.caB b0rk@social.jvns.ca

                  @literatesavant what's the answer?

                  literatesavant@mastodon.auL This user is from outside of this forum
                  literatesavant@mastodon.auL This user is from outside of this forum
                  literatesavant@mastodon.au
                  wrote sidst redigeret af
                  #37

                  @b0rk there are 8 "sections" of the man page. I thought they were "levels."
                  1: user commands
                  2: system calls
                  3: library functions
                  4: special files (devices and stuff)
                  5: file formats
                  6: games!
                  7: miscellaneous
                  8: system admin commands

                  So if you run "man crontab" you will see the crontab command arguments, and if you run "man 5 crontab" you will see the crontab file format.

                  literatesavant@mastodon.auL 1 Reply Last reply
                  0
                  • literatesavant@mastodon.auL literatesavant@mastodon.au

                    @b0rk there are 8 "sections" of the man page. I thought they were "levels."
                    1: user commands
                    2: system calls
                    3: library functions
                    4: special files (devices and stuff)
                    5: file formats
                    6: games!
                    7: miscellaneous
                    8: system admin commands

                    So if you run "man crontab" you will see the crontab command arguments, and if you run "man 5 crontab" you will see the crontab file format.

                    literatesavant@mastodon.auL This user is from outside of this forum
                    literatesavant@mastodon.auL This user is from outside of this forum
                    literatesavant@mastodon.au
                    wrote sidst redigeret af
                    #38

                    @b0rk if you don't specify a level, the default search order is 1, 8, 2-7.

                    1 Reply Last reply
                    0
                    • radieschen@climatejustice.socialR This user is from outside of this forum
                      radieschen@climatejustice.socialR This user is from outside of this forum
                      radieschen@climatejustice.social
                      wrote sidst redigeret af
                      #39

                      @clarfonthey I thought about this while trying some of the options. I came to the conclusion that it would be weird to tell a woman to (please) look something up for me.

                      I remembered that factory_girl (a ruby library to create test factories) was renamed to factory_bot a while ago. There is a blog post about it, the reasoning is similar.
                      https://thoughtbot.com/blog/factory_bot#why

                      Then I found a comment by a woman arguing it's potentially overblown and now I'm confused.
                      https://github.com/thoughtbot/factory_bot/issues/921#issuecomment-243173849

                      It's quite an interesting discussion on feminism from almost 10 years ago. The maintainers decided to rename the project even though the comments that argued for the change did get a lot of thumbs down.

                      Another thought was that woman would be too much to type, I'd prefer something like gal.

                      qman looks nice, but since it seems to be slow, I didn't bother trying harder. I think I'll give batman a try and also found out about tldr and might test some other things.

                      I guess if there is a rust implementation of qman, it could be either called gal, or it couldn't.

                      That was an interesting and productive couple of hours of procrastination, thanks for the question @b0rk

                      clarfonthey@toot.catC 1 Reply Last reply
                      0
                      • b0rk@social.jvns.caB b0rk@social.jvns.ca

                        i feel like i've probably asked this before but has anyone written a fancy command line man page viewer to replace `man`?

                        (not emacs or vim)

                        paniash@mstdn.socialP This user is from outside of this forum
                        paniash@mstdn.socialP This user is from outside of this forum
                        paniash@mstdn.social
                        wrote sidst redigeret af
                        #40

                        @b0rk I know you said no emacs but I really like the in-built emacs package called `woman`.

                        1 Reply Last reply
                        0
                        • radieschen@climatejustice.socialR radieschen@climatejustice.social

                          @clarfonthey I thought about this while trying some of the options. I came to the conclusion that it would be weird to tell a woman to (please) look something up for me.

                          I remembered that factory_girl (a ruby library to create test factories) was renamed to factory_bot a while ago. There is a blog post about it, the reasoning is similar.
                          https://thoughtbot.com/blog/factory_bot#why

                          Then I found a comment by a woman arguing it's potentially overblown and now I'm confused.
                          https://github.com/thoughtbot/factory_bot/issues/921#issuecomment-243173849

                          It's quite an interesting discussion on feminism from almost 10 years ago. The maintainers decided to rename the project even though the comments that argued for the change did get a lot of thumbs down.

                          Another thought was that woman would be too much to type, I'd prefer something like gal.

                          qman looks nice, but since it seems to be slow, I didn't bother trying harder. I think I'll give batman a try and also found out about tldr and might test some other things.

                          I guess if there is a rust implementation of qman, it could be either called gal, or it couldn't.

                          That was an interesting and productive couple of hours of procrastination, thanks for the question @b0rk

                          clarfonthey@toot.catC This user is from outside of this forum
                          clarfonthey@toot.catC This user is from outside of this forum
                          clarfonthey@toot.cat
                          wrote sidst redigeret af
                          #41

                          @radieschen @b0rk honestly, I'm going to have to agree with the notion that people are thinking way too much into it

                          that said, I personally don't even fully type out most commands; for example, I have g aliased to git, and that's only 3 letters

                          1 Reply Last reply
                          0
                          • rjbs@social.semiotic.systemsR rjbs@social.semiotic.systems

                            @b0rk Ugggggh if you find a good answer, please repost it with a bright red light. I think the biggest issue is that the roff format is too bankrupt, and we need better linking primitives, but… I might just be jaded.

                            fanf@mendeddrum.orgF This user is from outside of this forum
                            fanf@mendeddrum.orgF This user is from outside of this forum
                            fanf@mendeddrum.org
                            wrote sidst redigeret af
                            #42

                            @rjbs @b0rk the BSD -mdoc macros are much nicer than the old -man macros: mdoc has rich semantic markup and some basic support for hyperlinks

                            mdoc is fairly nice to edit despite the dot-line commands and the terse two-letter abbreviations

                            and the mandoc utilities do a beautiful job of turning mdoc man pages to html

                            i wonder how well mandoc -Thtml | w3m works compared to the old w3mman wrapper…

                            1 Reply Last reply
                            0
                            • b0rk@social.jvns.caB b0rk@social.jvns.ca

                              i feel like i've probably asked this before but has anyone written a fancy command line man page viewer to replace `man`?

                              (not emacs or vim)

                              wookieeboy@hachyderm.ioW This user is from outside of this forum
                              wookieeboy@hachyderm.ioW This user is from outside of this forum
                              wookieeboy@hachyderm.io
                              wrote sidst redigeret af
                              #43

                              @b0rk because sometimes you just want a simple reading experience:

                              man -t $1 | open -f -a /Applications/Preview.app

                              b0rk@social.jvns.caB 1 Reply Last reply
                              0
                              • wookieeboy@hachyderm.ioW wookieeboy@hachyderm.io

                                @b0rk because sometimes you just want a simple reading experience:

                                man -t $1 | open -f -a /Applications/Preview.app

                                b0rk@social.jvns.caB This user is from outside of this forum
                                b0rk@social.jvns.caB This user is from outside of this forum
                                b0rk@social.jvns.ca
                                wrote sidst redigeret af
                                #44

                                @wookieeboy whoa Preview has a man page reader?? I can't get it to work but that's interesting

                                wookieeboy@hachyderm.ioW 1 Reply Last reply
                                0
                                • b0rk@social.jvns.caB b0rk@social.jvns.ca

                                  @wookieeboy whoa Preview has a man page reader?? I can't get it to work but that's interesting

                                  wookieeboy@hachyderm.ioW This user is from outside of this forum
                                  wookieeboy@hachyderm.ioW This user is from outside of this forum
                                  wookieeboy@hachyderm.io
                                  wrote sidst redigeret af
                                  #45

                                  @b0rk preview can open postscript files. I haven’t used that in a while. It used to be that -t on man would generate postscript for printing.

                                  b0rk@social.jvns.caB 1 Reply Last reply
                                  0
                                  • wookieeboy@hachyderm.ioW wookieeboy@hachyderm.io

                                    @b0rk preview can open postscript files. I haven’t used that in a while. It used to be that -t on man would generate postscript for printing.

                                    b0rk@social.jvns.caB This user is from outside of this forum
                                    b0rk@social.jvns.caB This user is from outside of this forum
                                    b0rk@social.jvns.ca
                                    wrote sidst redigeret af
                                    #46

                                    @wookieeboy thanks! I do get a postscript file but for some reason Preview won't open it, who knows why

                                    wookieeboy@hachyderm.ioW 1 Reply Last reply
                                    0
                                    • b0rk@social.jvns.caB b0rk@social.jvns.ca

                                      @wookieeboy thanks! I do get a postscript file but for some reason Preview won't open it, who knows why

                                      wookieeboy@hachyderm.ioW This user is from outside of this forum
                                      wookieeboy@hachyderm.ioW This user is from outside of this forum
                                      wookieeboy@hachyderm.io
                                      wrote sidst redigeret af
                                      #47

                                      @b0rk I'm starting to think that Preview doesn't like to open postscript any more. Even a more verbose version fails to open

                                      man -t sudo > /tmp/sudo.ps && open -a "Preview" /tmp/sudo.ps

                                      wookieeboy@hachyderm.ioW 1 Reply Last reply
                                      0
                                      • wookieeboy@hachyderm.ioW wookieeboy@hachyderm.io

                                        @b0rk I'm starting to think that Preview doesn't like to open postscript any more. Even a more verbose version fails to open

                                        man -t sudo > /tmp/sudo.ps && open -a "Preview" /tmp/sudo.ps

                                        wookieeboy@hachyderm.ioW This user is from outside of this forum
                                        wookieeboy@hachyderm.ioW This user is from outside of this forum
                                        wookieeboy@hachyderm.io
                                        wrote sidst redigeret af
                                        #48

                                        @b0rk Now I'm a little bit sad.

                                        1 Reply Last reply
                                        0
                                        • flohw@pouet.chapril.orgF flohw@pouet.chapril.org

                                          @b0rk I use [bat](https://github.com/sharkdp/bat) with this env var `export MANPAGER="sh -c 'col -bx | bat --language man --plain'"`
                                          This look like this.

                                          marcusxms@helvede.netM This user is from outside of this forum
                                          marcusxms@helvede.netM This user is from outside of this forum
                                          marcusxms@helvede.net
                                          wrote sidst redigeret af
                                          #49

                                          @flohw @b0rk I've loved having "fish-colored-man" installed, partially because of its name, but this actually seems even better. Thanks!

                                          1 Reply Last reply
                                          0
                                          Svar
                                          • Svar som emne
                                          Login for at svare
                                          • Ældste til nyeste
                                          • Nyeste til ældste
                                          • Most Votes


                                          • Log ind

                                          • Har du ikke en konto? Tilmeld

                                          • Login or register to search.
                                          Powered by NodeBB Contributors
                                          Graciously hosted by data.coop
                                          • First post
                                            Last post
                                          0
                                          • Hjem
                                          • Seneste
                                          • Etiketter
                                          • Populære
                                          • Verden
                                          • Bruger
                                          • Grupper