I am having a bit of a brain freeze here but I would like to install pandoc but I don’t want to disable the default steam deck settings to do so even though using pacman on the command line would be way simpler I don’t want to fiddle if I don’t have to fiddle.

https://pandoc.org/

Can I not just download a binary and point Linux towards it? I know this is a silly question but frustratingly I am more familiar with how you are supposed to do this on windows with the $home variable nonsense.

  • thingsiplay@lemmy.ml
    link
    fedilink
    arrow-up
    9
    ·
    3 days ago

    SteamOS on Steam Deck supports Nix packaging system, besides pacman. pandoc is in the Nix repositories: https://search.nixos.org/packages?channel=25.11&query=pandoc The Nix packaging does not require you to disable read only, as Valve did an exception for this. It should also persist between updates, if I understand this right.

    Having said this, i did not ever use the Nix packaging system on Steam Deck (yet). So I cannot assist with advice and have no idea how easy is it to pull off. Here is a random article to set it up once: https://chrastecky.dev/gaming/persistent-packages-on-steam-deck-using-nix The good thing is, once Nix is setup, one can use it for other stuff too.

    • pivot_root@lemmy.world
      link
      fedilink
      arrow-up
      3
      ·
      3 days ago

      It works about the same as any other non-NixOS system running a user install of Nix.

      nix-env -i neovim
      

      You could also choose to enable and use more advanced features like flakes, but I would suggest not doing that unless you want to dive into the Nix ecosystem.

    • SteleTrovilo@beehaw.org
      link
      fedilink
      arrow-up
      2
      ·
      3 days ago

      This. Nix on SteamOS works great and gets you access to a lot of packages, easily. Set up Nix, then Pandoc is just right there.

  • khannie@lemmy.world
    link
    fedilink
    English
    arrow-up
    6
    ·
    edit-2
    3 days ago

    Not at my deck right now as it’s late here but they do provide a statically linked binary on their download page which should be all you need.

    The one you want is:

    https://github.com/jgm/pandoc/releases/download/3.9.0.2/pandoc-3.9.0.2-linux-amd64.tar.gz

    Download that and extract it somewhere / anywhere and you should be able to run it directly.

    You may need to add “execute” permissions to it after extraction but probably not.

    Edit: if you’ve any troubles give me a poke and I’ll get you exact instructions in the morning here.

    • supersquirrel@sopuli.xyzOP
      link
      fedilink
      arrow-up
      2
      ·
      3 days ago

      Thank you for pointing out the specific file, that was helpful confirmation but I do not seem to be able to run it either by running it in the command line or by changing its properties to be able to be executed as a program.

      • Fubarberry@sopuli.xyzM
        link
        fedilink
        English
        arrow-up
        4
        ·
        3 days ago

        The binary is a command line only program, usual format for running it is ./pandoc inputfile -o outputfile"

        If you want it runable anywhere from command line, you can put the downloaded binary in ~/.local/bin

        I don’t know what exactly you want to use pandoc for, but you might also consider Morphosis. It’s in the discovery store and I think it’s a graphical front end for pandoc.

        • khannie@lemmy.world
          link
          fedilink
          English
          arrow-up
          3
          ·
          edit-2
          3 days ago

          OK so I remembered. Downloaded and extracted it. Not a tool I’m familiar with but it worked fine first time. It’s command line so I opened up a command prompt and got this output (snipped a bit as the output was long):

          (deck@steamdeck ~)$ cd Downloads/pandoc-3.9.0.2/bin/
          (deck@steamdeck bin)$ ./pandoc --help
          pandoc [OPTIONS] [FILES]
            -f FORMAT, -r FORMAT  --from=FORMAT, --read=FORMAT                                          
            -t FORMAT, -w FORMAT  --to=FORMAT, --write=FORMAT                                           
            -o FILE               --output=FILE     
            etc......
          

          Does that help?

          I see you’re coming from windows so how comfortable are you with the command line? I see someone else mentioned that there is a frontend available which might be more useful to you if the answer is “not very”.

          FYI tab is your friend on the command line as it will autofill stuff for you. So I didn’t actually type “cd Downloads/pandoc-3.9.0.2/bin/” I just typed cd Down (tab) p (tab) and it filled it to “cd Downloads/pandoc-3.9.0.2/”

          edit: The ./ is essential once you’re in the directory when you’re running stuff this way. It essentially means “in this directory, run …”. Otherwise the shell will just look in your $PATH directories list and not find “pandoc” anywhere in it. You can add “.” to your $PATH to avoid this but it’s not there by default on the deck.

          Mine is:

          (deck@steamdeck bin)$ echo $PATH
          /usr/local/sbin:/usr/local/bin:/usr/bin:/var/lib/flatpak/exports/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl
          

          Last thing - I know you weren’t confident picking the right package to download. For binaries you’re always looking for stuff with “linux-amd64” or similar in the name for the deck.

          There’s also a cool little community that you might like called “Linux Upskill Challenge” which you can find at:

          !linuxupskillchallenge@programming.dev

          It brings you through basics on a day by day basis and on to slightly more advanced stuff as you go.

          • supersquirrel@sopuli.xyzOP
            link
            fedilink
            arrow-up
            2
            ·
            edit-2
            2 days ago

            edit: The ./ is essential once you’re in the directory when you’re running stuff this way. It essentially means “in this directory, run …”. Otherwise the shell will just look in your $PATH directories list and not find “pandoc” anywhere in it. You can add “.” to your $PATH to avoid this but it’s not there by default on the deck.

            This was the issue, I am fairly comfortable with the command line there are just lots of little things that were never explained to me because I have learned it all myself.

            I appreciate the recommendation for a front end engine! I want pandoc for exporting org files to document/website formats from org mode in emacs so I don’t need a front end but I will definitely check it out!

            I actually think I still need to add pandoc to the $PATH directory so emacs can run it though.

      • khannie@lemmy.world
        link
        fedilink
        English
        arrow-up
        3
        ·
        3 days ago

        Righto. I’ll download it in the morning and get back to you with specifics.

        If you haven’t heard from me in 12 hours I’ve forgotten so give me a nudge please. Eyes closing here as it’s very late. :)

  • testingtesting123@discuss.tchncs.de
    link
    fedilink
    arrow-up
    2
    ·
    2 days ago

    You can use micromamba or brew as local and then install pandoc and run from the terminal. It will rest in your home so I don’t think it will get erased.

  • Lung@lemmy.world
    link
    fedilink
    arrow-up
    5
    ·
    3 days ago

    Just use pacman, it’s fine, and less fiddly than manually installing a binary to your PATH

      • Celediel@slrpnk.net
        link
        fedilink
        arrow-up
        4
        ·
        edit-2
        3 days ago

        No, but anything you change will be undone by the next update. Better to use something like distrobox, that’s stored in the home directory.

        You could theoretically download a binary, but you run into the chance of it being compiled against different versions of libraries than on the Steam Deck’s system. A statically linked binary would fix that particular issue, though.

        • rotopenguin@infosec.pub
          link
          fedilink
          English
          arrow-up
          1
          ·
          3 days ago

          I just accept that the occasional OS update will uninstall my few pacman programs. When that happens, I run a simple script to reinstall them.