Waffelson@lemmy.world to linuxmemes@lemmy.world · 2 years ago:wq!lemmy.worldimagemessage-square111fedilinkarrow-up1202arrow-down170
arrow-up1132arrow-down1image:wq!lemmy.worldWaffelson@lemmy.world to linuxmemes@lemmy.world · 2 years agomessage-square111fedilink
minus-squaremeow@lemmy.blahaj.zonelinkfedilinkarrow-up21·2 years agoyou don’t need the ! when you have the w, because your changes already get saved.
minus-squareraptir@lemdro.idlinkfedilinkEnglisharrow-up18·2 years agoIf anything it is dangerous as it will still exit even if changes cannot be saved.
minus-squareDocMcStuffin@lemmy.worldlinkfedilinkarrow-up5·2 years agoTry editing a file in /etc as a regular user. It happens sometimes and you really want that warning that the write failed. Anyway, :x is superior. It only writes if there are changes. So, your mtime doesn’t change unnecessarily.
minus-squarecarcus@lemmy.mllinkfedilinkEnglisharrow-up4·2 years agoI’ve had to do forensics on a rogue change. In finding when and who actually changed the file, mtime can help narrow it down when compared with wtmp.
you don’t need the
!when you have thew, because your changes already get saved.If anything it is dangerous as it will still exit even if changes cannot be saved.
Try editing a file in
/etcas a regular user. It happens sometimes and you really want that warning that the write failed.Anyway,
:xis superior. It only writes if there are changes. So, your mtime doesn’t change unnecessarily.wait people care about the mtime?
I’ve had to do forensics on a rogue change. In finding when and who actually changed the file, mtime can help narrow it down when compared with wtmp.