One Liners And Things
I guess, moving forward I should start putting all my quick commands I find into a collection. Rather then thinking I can remember them. That thinking fails me more often than not, and I find myself searching the world again for that one thing that worked.
This will be my avenue for self preservation.
Remove SELINUX context from all files (the dot):
find / -exec setfattr -h -x security.selinux {} \;
Move the last 1000 1000 files to a different location:
ls -a1 | tail -n1000 | xargs -i mv {} ./location
Count the number of files in a directory:
ls | wc -l
Globally Disable VIM Auto-Indentation by Disabling the File
cd /usr/share/vim/vim80
mv### DISABLE cp -a indent.vim indent.vim.bak echo "" > indent.vim chattr +i indent.vim ### RESTORE chattr -i indent.vim rm -f indent.vim mv indent.vim.bak indent.vim
This will grow, foe show.grow...