Hi all,

I am about to do a bit of a distro hop, and I am looking at Fedora and its spins, after years on Debian / POP.

I am not looking forward to setting it all up again, it's a drag.

I wonder, is there a tool that lets me script installs?

I'll want to check if application exists, and if so, update, otherwise, install. That kind of thing.

Things like:

  • Telegram
  • Joplin
  • Docker
  • Firefox
  • Ungoogle Chromium
  • Sublime Text
  • VSCodium
  • Keepass
  • Thunderbird
  • DBeaver
  • Gimp
  • Inkscape
  • KDENLive
  • Syncthing
  • Steam
  • VLC
  • Localsend
  • Flameshot
  • Element
  • Cherrytree
  • Calibre
  • Anydesk

I show the list, only to give an idea of what might be involved.

I'm new to Fedora, so not sure how it differs beyond the package manager. But, thought I'd ask.

Does such a tool exist, and is it worth my time? I can practice on a VM before trying on the final install/s.

Thank you

  • Kuadhual@lemm.ee
    ·
    2 months ago

    Using ansible will help you on your 2nd, 3rd , nth install.

    But getting ansible to do what you want (plus testing) for the first time would takes 10x longer than manual install.

    I think there's xkcd about that.

  • qocu
    ·
    2 months ago

    I didn't find any script that would install the apps you wanted, but I did find a script that will help you build your own (it's pretty easy). You can take inspiration from this one and modify it, so that whenever you reinstall your system, you'll run your script.

    https://gist.github.com/engineervix/ed53aa410a22620013e04baca437abb3

    Research what commands are used in Fedora to install what application and add them to your script. Then, give your .sh file execute permissions and run it. You can do this in a virtual machine first if you want.

    • makingStuffForFun@lemmy.ml
      hexagon
      ·
      2 months ago

      ...aaaand DONE and tested. That was amazingly simple, when there's a framework like that to work, and learn from. Thanks again.

      • qocu
        ·
        2 months ago

        Wow, that was fast. Glad it helped you.

  • utopiah@lemmy.ml
    ·
    2 months ago

    I did more than 5 installs this weekend (for ... reasons) and the "trick" IMHO is ...

    Do NOT install things ahead of actually needing them. (of course this assume things take minutes to install and thus you will have connectivity)

    For me it meant Firefox was top of the list, VLC or Steam (thus NVIDIA driver) second, vim as I had to edit crontab, etc.

    Quite a few are important to me but NOT urgent, e.g Cura (for 3D printer) and OpenSCAD (for parametric design) or Blender. So I didn't event install them yet.

    So IMHO as other suggested docker/docker-compose but only for backend.

    Now... if you really want a reproducible desktop install : NixOS. You declare your setup rather than apt install -y and "hope" it will work out. Honestly I was tempted but as install a fresh Debian takes me 1h and I do it maybe once a year, at most, no need for me (yet).

    • utopiah@lemmy.ml
      ·
      2 months ago

      Another "trick" I use is having an ~/Apps directory in which I have AppImage, binaries, etc that I can bring from an old /home to a new one. It's not ideal, bypassing the package manager, and makes quite a few assumption, first architecture, but in practice, it works.

      • Samueru@lemmy.ml
        ·
        2 months ago

        Check this out: https://github.com/ivan-hc/AM

        Use appman and set the install directory to ~/Apps and now you will be able to install appimages/binaries in the ~/Apps dir using a package manager that keeps them up to date and that you can move to any other distro, I have all of this:

        Show

        Although more recently for binaries I've been using this instead, which pulls from a massive repo of static binaries, though note that dbin needs its own separate directory in HOME to install binaries (you can't use ~/Apps that is).

        Show

        • utopiah@lemmy.ml
          ·
          2 months ago

          Hmmm very interesting thanks for the links and explanation!

          I'm not "ready" for it yet so I've bookmarked all that (by adding a file in ~/Apps ;) but that's definitely and interesting, and arguably neater solution.

          Honestly I try to stick to the distribution package manager as much as I can (apt on Debian stable) but sometimes it's impossible. Getting binaries myself feels a bit "wrong" but usually works. Some, like yt-dlp as I see in your list, do have their own update mechanisms. Interesting to consider stepping back and consider the trade off. Anyway now thanks to you I know there are solutions for a middle ground!

          • utopiah@lemmy.ml
            ·
            2 months ago

            Also this is a good way to re-consider integration back, e.g. generating .desktop files for /.local/share/applications/ when using KDE rather than having to manually do it each time.

            • Samueru@lemmy.ml
              ·
              edit-2
              2 months ago

              This is already done automatically.

              AM puts the .desktop files in /usr/local/share/applications

              AppMan puts them in ${XDG_DATA_HOME:-~/.local/share}applications

              They also get symlinked in PATH, that is you can launch yt-dlp by typing yt-dlp on the terminal as if you had installed it with your distro package manager.

              • utopiah@lemmy.ml
                ·
                2 months ago

                Ah! Wonderful. I'm always a bit reluctant with system-wide install so I'll put AM on hold for now but probably tinker with AppMan/dbin soon.

                Out of curiosity, one of the app I'd usually get outside my package manager is Chromium. I'd usually download the latest build from https://download-chromium.appspot.com/ so in this situation, how would you do it using any of those solutions? Would it support adding extensions e.g https://chrome.google.com/webstore/detail/immersive-web-emulator/cgffilbpcibhmcfbgggfhfolhkfbhmik that I need for development?

                PS: note to self, go through bash history to see which failed apt install attempts could be replaced with such tools.

                • Samueru@lemmy.ml
                  ·
                  edit-2
                  2 months ago

                  Show

                  It pulls the latest chromium from googleapis.com so it can do everything.

                  • utopiah@lemmy.ml
                    ·
                    2 months ago

                    Very cool, sincere thank you for the clarification and even on-boarding process. Installed this way, feels quite efficient. Will dig a big deeper while using them more.

  • lens0021@lemmy.ml
    ·
    edit-2
    2 months ago

    Have you tried SaveDesktop? Thought It is limited in the flatpak softwares, but cloud synchronization feature is recently added.

    • TeryVeneno@lemmy.ml
      ·
      2 months ago

      Was looking for this in this comment section, I see this solution as becoming the goto for moving between installs even though it is limited right now

  • Samueru@lemmy.ml
    ·
    2 months ago

    I wonder, is there a tool that lets me script installs?

    I’ll want to check if application exists, and if so, update, otherwise, install. That kind of thing.

    https://github.com/ivan-hc/AM

    Use AppMan to install them in HOME.

    • LeLachs@lemmy.ml
      ·
      2 months ago

      It should be possible. Although probably very complicated. Have a look at https://distrobox.it/. It allows you to tightly integrate containers into your desktop, including accelerated graphics, some devices, your homedir, etc. It can even automatically install desktop shortcuts. (You can disable the integrations of course) Even tho it uses Podman instead of docker, AFAIK it should be 1:1 compatible with docker for your usecase.

      • eraclito@feddit.it
        ·
        2 months ago

        Have a look at https://distrobox.it/. It allows you to tightly integrate containers into your desktop, including accelerated graphics, some devices, your homedir, etc. It can even automatically install desktop shortcuts. (You can disable the integrations of course)

        Furthermore, distrobox allows you to define the list of packages to be installed, see:

        https://github.com/89luca89/distrobox/blob/main/docs/usage/distrobox-assemble.md

        • LeLachs@lemmy.ml
          ·
          2 months ago

          That is very cool. Thanks for sharing. If you need some additional repos (like OP), you can probably add them through some commands in the "pre_init_hooks" option.

  • merthyr1831@lemmy.ml
    ·
    2 months ago

    Some distros allow this. Nix for example allows you to save config files that describe your entire system (apps, settings, etc) and then load them in one go. Other distros are following suit with their own tailored solutions too (I think Ubuntu might have something? Manjaro?).

    • LeLachs@lemmy.ml
      ·
      2 months ago

      You can even have all nixpkgs on a different distro through the nix package manager