Earlier this year, I built a new PC and it’s running Ubuntu. I’ve been installing various apps and configuring them since then. Now, I realize I don’t have any way of knowing what I would want to reinstall, if I (for instance) lost this drive somehow.

How do you keep track of what you’ve installed/ your favorite apps?

Separately, how can I backup the configurations I’m using right now.

Thanks!

38 points

Git.

Keep all the config files of your tools in subdirectories of a git versioned directory and symlink them into their target location (e.g. with GNU stow). If installation of a tool is involved and you expect to have to revisit it, put the steps into an installation bash script and version it as well.

permalink
report
reply
3 points
*

+1, essential ones I keep in GitHub repository (like zsh, tmux, xdefaults configs with no personal data). With makefile that makes symlinks. This is the easiest way to sync zsh config between my personal and work machines.

Rest is just in a backup.

permalink
report
parent
reply
1 point

Do you have an example of a generalise makefile that does that? Or does it need to be customise per configuration?

permalink
report
parent
reply
3 points

On my GitHub repo. Needs to be customized, but you should get the idea.

Maybe there is a way to write it better, I’m no makefile expert ;)

permalink
report
parent
reply
1 point
*

@zacher_glachl @perishthethought I take a similar approach starting with a bare work-tree at $HOME/.cfg and add config files I’ve changed. Then throw my --git-dir and --work-tree switches in an alias for git.

As for installed programs, a simple backup of my portage world file takes car of that.

permalink
report
parent
reply
34 points
*
permalink
report
reply
7 points

Seconding this. Store your configuration.nix in git and just copy it back over if you ever need to wipe and reinstall.

permalink
report
parent
reply
18 points

Oh! I can participate!

Everything I have/configure is 100% in Ansible. I learned the hard way that rebuilding a workstation from scratch sucks if I only depend on my brain to remember things.

It takes some effort to keep it updated - if I’m trying out a new app, I have to remember to add it to my config.

The other thing that I’ve started doing is using Restic for file level backups. That’s relatively easy to set up, it supports a multitude of backend storage, and works well with a cron job for braindead backups.

permalink
report
reply
15 points

I just check my Nix.config, but most distros don’t have that privilege.

Idk how it works for most other distros, but I know on Arch you can check all packages manually installed by pacman and your AUR helper.

permalink
report
reply
2 points

Iirc pacman -Qe does something like this

permalink
report
parent
reply
14 points

Home Manager on a NixOS flake, it’s a rabbit hole but I’ve been loving it since last week!

permalink
report
reply

Linux

!linux@lemmy.ml

Create post

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word “Linux” in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

  • Posts must be relevant to operating systems running the Linux kernel. GNU/Linux or otherwise.
  • No misinformation
  • No NSFW content
  • No hate speech, bigotry, etc

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

Community stats

  • 8.4K

    Monthly active users

  • 6.3K

    Posts

  • 172K

    Comments