Bash
Jump to navigation
Jump to search
Search largest file
du -hs <dir>/* | sort -h
Of met exclude:
du -hs /* --exclude=/media/sdcard --exclude=/var --exclude=/home/rijk --exclude=/home/miel | sort -h
Search largest file recursively
find . -type f -exec ls -alh {} \; | sort -hr -k5 | head -n 25
Last changed files
ls -altR . | head -n 3
Recently installed packages
cat /var/log/dpkg.log | grep "\ install\ "
awk '$3~/^install$/ {print $4;}' /var/log/dpkg.log
Change file date
touch -m -a -t 201609021156 00002.m4v
Ls with year
ls -lahot --full-time