Spring Cleaning your Home! (~/, That is...)
Вставка
- Опубліковано 27 вер 2024
- Seeing someone with a messy home is like going over to someone's house and seeing their clothes and junk all over the living room floor. es em haitch tee bee haitch fam. Here I talk about setting environmental variables and taking advantage of the XDG directory specifications to minimize ugly dotfiles in your home directory.
WEBSITE: lukesmith.xyz 🌐❓🔎
DONATE NOW: lukesmith.xyz/... 💰😎👌💯
Remember kids! The only true way to be a minimalist is to recursively force rm your entire ~/!
do a meme review on tradwife pls
sudo rm -rf ~/.* is
yeah kids... just don't do a sudo rm -rf ~/../* - that would be a bit too minimalistic...
no no guys you also half to pass it this argument (--no-preserve-root) to get by the fail-safe so minimalism is more like this (#rm -rv --no-preserve-root /) p.s. new users this is a joke do not run that command you will nuke your computer. not that the data is gone completely as the disk space will not be overwritten with zeros or anything . but recovery is time consuming and not a 100%.
140... I blame windows.
Cheat code: Using 'A' instead of 'a' will improve your score by 2 points.
But it would be the more "correct" score, right? Since it doesn't list `.` and `..`, which is the same for all directories anyway
Luke really took the "boomer ranting in the woods" meme even further
I want to see a kernel compiled by a campfire! Everyone roasting marshmallows and you're enabling preempt and hardware specific flags...
@@jamesm5192
Campfire programming session!
Campfire programming session!
Campfire programming ses-
Luke: "Keep your home directory clean!"
Also Luke: Puts downloads in his home directory like a savage
I may do this too. I never really understood the Downloads folder.
@@stumbling To not get junk accumulate in your system. I usually save everything in Download till the download folder is like 10Gb or more where I do a simplce rm -r Downloads/*, saving them in the home directory you must delete them manually one by one.
I also save some downloads to home... it's like crack addiction, even if you move them to Downloads directory you still doenload random stuff to home...
Downloads belong in /tmp/ unless you go out of your way to save them.
@@alerighi This seems like having a very large rug to sweep things under rather than actually helping keep things organised.
Before watching this video: 50
After: 13
Thank you Luke Smith for inspiring me to clean my Home!
I have 75
I remember watching this video and not knowing a single thing that is going on. Life really goes downhill...
Me too...
Luke: mv ~/* .config/
Also Luke: muh my home is so clean
Wouldn't that also put .config in .config recursivelly?
@@amosnimos nope itll throw an exception and leave it out but move the rest
You should've used ls -A as it removes directory listing of . and ..
Man of culture.
best, thanks
ls -a is bloated af
He is reducing the additional effort of pressing shift. Minimalism.
@@RaveenKumar this is why you alias ls -A to la
/home sweet /home!
$ ls -1 | wc -l
1263
Lol. I got 62 and thought that was bad.
Not even "ls -1a", and that much.
Kind of a "yikes" as the kids would say.
@@elidrissii $ ls -1a | wc -l
1708
It's even more, YIKES
powerful...
I thought I had the worst with 131...
I have become way too obsessive about this. When I first saw the video I was at 90+ (although this included junk I didn't use anyway). I am now at 21. I even replaced some AUR packages with github versions so I could alter the source to make them comply with XDG specifications. :D
0:00 Luke Smith - Specter of the Great Library
lol, thanks
This is exactly the video I needed. Earlier today I was thinking about how to organize my home folder and wondering if it was okay to move all those hidden folders out of there.
put "export ZDOTDIR="$HOME/.config/zsh"
into /etc/zshenv (if it doesn't exist, create it)
zsh ALWAYS reads it, followed by the zshenv of the user, but that way you can put your user zshenv into your zsh folder. it will even work for other users that happen to use zsh on your system.
I'm very glad this exists now. I have needed this since the zsh conversion video.
I inherited an employment position from someone who decided to "clean up" the filesystem.
I've been doing this for ~1hour and went from 95 to 73 ! And still haven't made it through half the list yet... I got a bunch of pretty annoying ones like snap, ssh, steam, paradoxlauncher and mozzilia that don't support at all the xdg specs unfortunately... But thanks for making me discover this !
81
Apparently every program I use creates a dotfile in my home folder.
Same, almost every terminal program I have has a .history file in my home directory because they couldn't figure out a better place to put it
I like when you start typing the camera starts shaking.
before
ls -a | wc -l
~55
now
ls -a | wc -l
11
feels good man
This is the way
How did you get so low jesus! I bet you put your xdg_downloads in /tmp don't you
Oh, my result is 100.
I reinstalled my system a few months ago.
In my old home directory it's even 300.
I guess, part of the reason is, that my screenshots done with "import name.png" land in home.
After moving them, it's only 83.
I also have a few random text files in my home, which I stored in home directly because of convenience.
After moving them, it's only 71.
And most of them are some config files or directories (the ones starting with a dot): 48
Then I have a few other files (one video, one pdf, one text document without an ending, and similar, less then 10).
And a few directories, which were mostly there form the beginning, but also some, I added for my own needs (bin, Blender, Unity).
141
I like chaos. Cannot live without it.
I was actually waiting for a video on this topic. Thanks a lot king
Thanks for the video. My full home folder always annoyed me but thanks to the wiki link it's much better now.
Nice shot of Trinity Library
Woah, was pretty sure my 73 would be mess, but you guys are just brutal.
0:23 Should really make that “ls -A”.
So its actually 16? 🤯
@Luke Smith
You can create /etc/zsh/zshenv with these lines inside it. Then you can move your ~/.zshenv to the ~/.config/zsh directory
#!/bin/sh
[ "$USER" = "luke" ] && ZDOTDIR="$HOME/.config/zsh"
big brain
I got 65, and I only have two months with my Arch installlation.
64 like a true Computer Scientist
I had 43 and a lot of those were folders like 'Music' or '.steam'.
"Set your Home directory in perfect order before you criticize the World directory" - Luke Peterson
47 right now, but most of them are hidden, like .git, .BurpSuite, etc
56. I did better than I expected
22. Thank you based minimalism god.
You should have explained .local and .cache and how you use them. That would have been helpful. For instance, what's the ideal location for Node global packages? Or custom builds of Suckless software?
suckless builds: ~/.local/src
npm packages: /dev/null
Frankly I think it's better to have a lot of stuff on FS in some directory than to have too many environmental variables set. All of these exports end up in one global namespace (ENV) while the files are at least namespaced by directory they're placed in (home).
$ env | wc -l
Agreed. Just use the defaults in tandem with a version-controlled GNU Stow directory. Way less overhead both cognitively and computationally.
his head floating in the beginning freaked me out
4:48 sound of bird
before watching: 18, after watching: 8.. thx luke
What about /bin mess ? Compare it with BSD, BSD’s userland is tidier. Please consider switching to BSD, GNU is bloated.
Serhan Ekmekçi redox
When will BSD start supporting current technologies?
Mario Zenarju When people start to use and support development of it instead of GNU/Linsux
IDK what you mean. I use busybox for things required to bring the system up, and no programs non-essential to initialization are allowed in, or to touch /bin /sbin /lib /etc
I am talking about seperation of /bin, /sbin, /usr/local/bin. Linux userland is just a mess.
For those program for which there are no options for changing the config directory you can use the following:
env HOME=/path/to/custom/config/folder name-of-the-program
It will run the program with the same env variables but the HOME one, so it is gonna trash the folder you specified
I just finished setting up manjaro and I have 33
I’m loving these videos lately
"smaller is better"
Nice
I grabbed a 2 tb external drive and moved all my crap off my desktop and some other directories, only to find out the external drive is far too small. At least 10 years of work... spending now several days doing decade level spring cleaning, but also releasing a lot of code I've written as open source projects.
I did the homework... from 87 to 52.
204... and one of those is a.out.
I have some cleaning to do
Yes
12, just installed OSX
I got 48.
Its mostly old dotfiles, I hate those things!
THANKS LUKE
I think I'll just abandon my Home directory itself at this point and treat it as a config folder lol. It's a lost cause
number 2 !!
57, but that's why I'm here.
The mad lad finally did it! Video saved!
100 bro literally everything is a .directory and i have zero clue what is or isn't being used as a dependency for another program
ok down to 33 i half suspect everything to break as soon as i restart
53.... Not bad for an actual messy person
ls -A doesn't show . and .. (of course you can just remove those with rm -R if they are bothering you)
Prior to watching I had 88 files, 2 hours later I have 28. Feels satisfying, but to be honest I'm not sure if it was worth it... Nice video btw, the arch site was very helpful
not worth it, it will break your system soon
It was 75, but now I have got it down to 23.
I got 90. Feels bad, man.
❯ lsd -a | wc -l
49
The offenders who don't respect XDG variables:
SoulseekQt
mono
aqbanking
dropbox (WIP for getting rid of this thing)
mozilla
steam
newsboat (there must be a way to set thing right?)
factorio
npm
gtkrc-2.0 ( I have set GTK2_RC_FILES)
nvidia-settings-rc
paradoxlauncher
vscode-oss
kde4
Luke: If you got more than a hundred, I don't know what's wrong with you
My ls -a | wc -l: 211
oopsie
51 and some of those I could easily get rid of.
29. I'm so messy, I expected a way higher number....
I literally had a clean install 1 week ago and I have 35 bruh
> ls -A | wc -l
18
(using -A instead of -a) but I'm on macOS, and Finder automatically creates .Trash, Desktop, Documents, Movies, Music and Pictures folders which are all empty, and if this wasn't enough to make it a garbage os, I have to have a .CFUserTextEncoding file which who tf knows what it does.
So really it's 11.
Went from 100+ to 20. Aaaand my arch is broken.
5:17 So now instead of dotfile clutter, you have environment clutter instead.
I saw that thread on /g/ too
Kek
71 and installed mint in last 2 months
>wants to be clean
>uses the bloatware that is Vim (doesn't even AT LEAST use neovim)
>hasn't switch from boomer-editor Vim to based and redpilled Kakoune
i think he uses neovim now
Where can I get a hold of that cool background? Also, what do you use to record your videos and screen at the same time? Thanks.
Hi Luke, Isn't it better to put all env vars into .profile ?
4240 is fine.
I got 37 and then realized I was ssh'ed into my mac. Back on my main linux box I got 80 :(
you should do a video about stow
15 year old install - 270 files (actually mostly dirs).
i don't even mind. but .config might use some cleanup
What distro do you use?
@@claytonsililo8428 Gentoo, but it doesn't really matter.
With how much I reinstall out of habit, getting to fifteen weeks is a challenge, let alone years.
@@liyifenn I was the same but now I'm stuck with KDE Neon and Xubuntu which are essentially Ubuntu.
@@yoshi314 Gentoo, I've been wanting to give it a spin but ah laziness always pulls me back.
Guess I'll just have to try it. By the way how well does it work?
24 is my result...
I always try to clean up my home dir, adding environment variables, aliases with --directory opts.
But there are some annoying pieces of software that do not want to leave my home directory, like...
ssh, pki, npm, nuget, mono, steam, xorg...
320, i have no idea why i suck at organization (but some aren't configs, some are symlinks and some are regular files)
45.. It is good for me. I do not want to clean
I reckon my number will overflow wc 👀
Did a little cleanup
ls -A | wc -l
33
(Was 40)
25 with a KDE Manjaro install
Before I watch this video - is that background the library at Trinity College Dublin? Because that's my background. I'm not sure what to think about this.
My friend told me that this command helps with cleaning:
rm -rf .
43 checking in
Is it just coincidence that last night I saw that _Family Guy_ episode where Lois goes all Marie Kondo and ends up evicting her entire family?
are we counting Windows users?
74, 51 excluding backups
:(
I have only 23 dotfiles/folders though
124... I'm a monster!!
202
Beat that
i thought 42 must have been bad but Jesus Christ there are some messy people here
83
I can live with that
31... I prefer using ~ instead of .config/ or .local/ that why
55, honestly shocked.
excellent idea.. needed to move sum stranded files to the correct location .. ls -a gives me 33 files.
but that's with all the .dot files. ls -l gives me 11 files.
146 files - on the user I abandonned for the specific reason to clean my directory and move everything that can be moved to their XDG counterpart.
Currently I have 24 (I could possibly get rid of the 3 .bash-files as I'm using zsh, but I don't know if anything will need them)
ls ~ -a | wc -l
149
and I am fine with that.... You know what? It's a prime number; I love it!!
what kind of monster only cleans his home on specific cleaning days?
Before: 70+
Now: 18
Thanks :D