645
We've all been there... (sh.itjust.works)

I usually use .bak... .old seems so... old.

top 50 comments
sorted by: hot top controversial new old
[-] d_k_bo@feddit.de 66 points 1 year ago

That's why you put your config files in a git repository

[-] skulbuny@sh.itjust.works 38 points 1 year ago

Sounds like Nixos with extra steps

[-] iopq@lemmy.world 8 points 1 year ago* (last edited 1 year ago)

What do you mean? My NixOS config files are in a git repository

[-] stepan@lemmy.cafe 14 points 1 year ago

Even the system files like those in /etc ?

[-] d_k_bo@feddit.de 6 points 1 year ago

No. I only set up /etc/fstab and /etc/ssh/sshd_config once and they will never change.

[-] herrcaptain@lemmy.ca 9 points 1 year ago

Package manager: This package contains an updated sshd_config file, would you like to replace your existing file with the package maintainer's updated file?

Me, every time: LOL, no

[-] fossphi@lemm.ee 3 points 1 year ago

Shit, thanks for reminding me. I needed to take care of some pacdiff files

[-] exu@feditown.com 5 points 1 year ago

Yes. I use a hacky script to copy them to the right place

[-] digdug@kbin.social 4 points 1 year ago

You could set up btrfs snapshots, too. Of course, don't forget to take a snapshot before you break your configs.

load more comments (2 replies)
[-] bappity@lemmy.world 45 points 1 year ago

BAK IN MY DAY πŸ‘΅πŸ‘΄

[-] Chocrates@lemmy.world 22 points 1 year ago

Yep I still add .bak to mine

[-] _______@poeng.link 35 points 1 year ago

Evolution:

  • config.json
  • config.json.bak
  • config.json.bak.old
  • config.json.bak.old2
  • config.json.bak.old3.stillworks
  • config.json.bak.old3.stillworks.DONTUSETHIS
  • config.json_(redownloaded_from_source)
[-] JasonDJ@lemmy.zip 7 points 1 year ago* (last edited 1 year ago)

Sigh...

git revert HEAD
echo \*.json.\* >> .gitignore
git commit
[-] Deway@lemmy.world 5 points 1 year ago
  • config.json.almost
  • config.json.broken
  • config.json.shouldwork
[-] user224@lemmy.sdf.org 5 points 1 year ago

config.conf
config.conf.backup
config.conf.testing
config.conf.old
config.conf.default
config.conf.example

[-] dogsnest@lemmy.world 15 points 1 year ago* (last edited 1 year ago)
[-] 0x4E4F@sh.itjust.works 4 points 1 year ago

True story... happens all the time.

[-] Knock_Knock_Lemmy_In@lemmy.world 11 points 1 year ago

Gmail says sending myfile.zip is not allowed.

Change it to myfile.zip.txt and everything is fine.

[-] user224@lemmy.sdf.org 4 points 1 year ago

It may be due to their processing.
Better base64 -w 0 myfile.zip > myfile.zip.txt

If it works though ¯⁠\⁠_⁠(⁠ツ⁠)⁠_⁠/⁠¯

[-] LaggyKar@programming.dev 9 points 1 year ago

Speaking of which, nowadays KDE hides files with these extensions for some reason

[-] 0x4E4F@sh.itjust.works 19 points 1 year ago* (last edited 1 year ago)

It's just a playful thing dolphins do 😊.

[-] Johanno@feddit.de 6 points 1 year ago

Rename to .old

Bam file is gone.

??? Confused look.

The heck?

Ctrl + h

Oh there it is!

[-] meekah@lemmy.world 8 points 1 year ago

I never really have hidden files off, so I wasn't even aware dolphin does this lol

[-] jws_shadotak@sh.itjust.works 2 points 1 year ago

I absolutely despise the idea of "hidden" files. I don't understand the purpose of not showing them.

[-] PoolloverNathan@programming.dev 2 points 1 year ago

It's useful to hide clutter. It's easier to look at the file you care about when the file~, file.old, .file.swp, #file#, file,v, etc. aren't in the way.

[-] LordOfLocksley@lemmy.world 8 points 1 year ago
[-] 0x4E4F@sh.itjust.works 2 points 1 year ago

Ah, yes, I also add dates sometimes, very helpful πŸ‘.

And then wonder "wtf did I change them πŸ€”".

Config files need git nowadays.

[-] Mouselemming@sh.itjust.works 7 points 1 year ago* (last edited 1 year ago)

I'm seeing this on oldsh.itjust.works, feels extra meta

https://oldsh.itjust.works/post/19853381

[-] Chocrates@lemmy.world 7 points 1 year ago

Is there a tool to version your configs? I use chezmoi for my dotfiles but that doesn't help system configs

[-] Nomad@infosec.pub 11 points 1 year ago
[-] ahal@lemmy.ca 7 points 1 year ago* (last edited 1 year ago)

An old manager of mine's backup solution was a cronjob that appended .old to every file then made a copy of the most recent one. So he had: file, file.old, file.old.old, file.old.old.old, ...

load more comments (1 replies)
[-] Crow 7 points 1 year ago

.bak is good, ranger even hides files with it

load more comments (1 replies)
[-] abadbronc@lemmy.world 6 points 1 year ago

Fuck it. What's the worst that could happen?

Oh.

[-] whotookkarl@lemmy.world 5 points 1 year ago* (last edited 1 year ago)

I like adding a backup function to .profile that can take a file or list of files as an argument and make a copy with a date suffix on the file name, and same date additional backups just add a character like ~ at the end. It's in version control, but if I'm testing a change it's just faster to restore the file from a copy in the same place.

[-] lseif@sopuli.xyz 3 points 1 year ago

i so agree. i have a script that copies all file arguments into the directory .backups/YYYY-mm-DD-HHMM/ ... handy for risky git operations too.

[-] palordrolap@kbin.social 2 points 1 year ago

Obligatory note that /etc/profile and ~/.profile are only run by login shells, and many terminal emulators do not execute a login shell by default.

Unfortunately, there is no standard secondary place* that all shells execute, so check your chosen shell's manual for what it does run on startup and put your functions into one of those. Preferably one that goes in your homedir.

Alternatively have that file source ~/.profile assuming that won't cause an infinite loop.

* And not even a primary if you count *csh, but if you use those you have other problems.

[-] Phoenix3875@lemmy.world 5 points 1 year ago
load more comments (1 replies)
[-] marcos@lemmy.world 3 points 1 year ago

*~

But you should really have a backup system. And often you should have a version control system too.

[-] darkpanda@lemmy.ca 4 points 1 year ago

Use etc-keeper, saves everything in a git repo and integrates with a bunch of package managers. Been using it for decades it feels like now.

[-] Sam_Bass@lemmy.world 3 points 1 year ago

Bet the world would be a happier place if we had cartoon physics

[-] 0x4E4F@sh.itjust.works 2 points 1 year ago

Lower gravity by 20x, bam, instant cartoon physics.

[-] possiblylinux127@lemmy.zip 2 points 1 year ago* (last edited 1 year ago)

Acceleration would be 0.50 m/s^2

[-] vynlwombat@lemmy.world 1 points 1 year ago

Did this with PAM the other day and nearly locked myself out.

load more comments
view more: next β€Ί
this post was submitted on 25 May 2024
645 points (100.0% liked)

linuxmemes

26067 readers
695 users here now

Hint: :q!


Sister communities:


Community rules (click to expand)

1. Follow the site-wide rules

2. Be civil
  • Understand the difference between a joke and an insult.
  • Do not harrass or attack users for any reason. This includes using blanket terms, like "every user of thing".
  • Don't get baited into back-and-forth insults. We are not animals.
  • Leave remarks of "peasantry" to the PCMR community. If you dislike an OS/service/application, attack the thing you dislike, not the individuals who use it. Some people may not have a choice.
  • Bigotry will not be tolerated.
  • 3. Post Linux-related content
  • Including Unix and BSD.
  • Non-Linux content is acceptable as long as it makes a reference to Linux. For example, the poorly made mockery of sudo in Windows.
  • No porn, no politics, no trolling or ragebaiting.
  • 4. No recent reposts
  • Everybody uses Arch btw, can't quit Vim, <loves/tolerates/hates> systemd, and wants to interject for a moment. You can stop now.
  • 5. πŸ‡¬πŸ‡§ Language/язык/Sprache
  • This is primarily an English-speaking community. πŸ‡¬πŸ‡§πŸ‡¦πŸ‡ΊπŸ‡ΊπŸ‡Έ
  • Comments written in other languages are allowed.
  • The substance of a post should be comprehensible for people who only speak English.
  • Titles and post bodies written in other languages will be allowed, but only as long as the above rule is observed.
  • 6. (NEW!) Regarding public figuresWe all have our opinions, and certain public figures can be divisive. Keep in mind that this is a community for memes and light-hearted fun, not for airing grievances or leveling accusations.
  • Keep discussions polite and free of disparagement.
  • We are never in possession of all of the facts. Defamatory comments will not be tolerated.
  • Discussions that get too heated will be locked and offending comments removed.
  • Β 

    Please report posts and comments that break these rules!


    Important: never execute code or follow advice that you don't understand or can't verify, especially here. The word of the day is credibility. This is a meme community -- even the most helpful comments might just be shitposts that can damage your system. Be aware, be smart, don't remove France.

    founded 2 years ago
    MODERATORS