#!/bin/bash
LOCATIONS=( "/" "/var" "/home" "/tmp" )LOCATIONS_RO=( "/usr" )
for LOCATION in ${LOCATIONS[*]}do    /usr/bin/dd bs=4096 if=/dev/zero of=${LOCATION}/0 ; rm ${LOCATION}/0done
for LOCATION in ${LOCATIONS_RO[*]}do  /usr/bin/mount ${LOCATION} -o rw,remount && /usr/bin/dd bs=4096 if=/dev/zero of=${LOCATION}/0 ; rm ${LOCATION}/0  mount ${LOCATION} -o remountdone
#!/bin/sh
/usr/bin/sed -i 's/mouse=a/mouse=r/g' /usr/share/vim/vim90/defaults.vim
#!/bin/bash
BACKUP_DIR="/home/BACKUPS/config/"EXT=".zst"MAX_FILES=30
# Znajdź pliki, posortuj według daty modyfikacji (najstarsze pierwsze)mapfile -t files < <(find "$BACKUP_DIR" -maxdepth 1 -type f -name "*$EXT" -printf "%T@ %p\n" | sort -n | awk '{print $2}')
file_count=${#files[@]}
if (( file_count > ${MAX_FILES} )); then    files_to_delete=$((file_count - ${MAX_FILES}))    for ((i=0; i<files_to_delete; i++)); do        rm -f -- "${files[$i]}"    donefi