1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950 |
- #!/bin/bash
- # Coding: utf-8
- # Editor: www.geany.org
- # Created 2020-08-03
- #_sudo_apt_install_ trash-cli
- #_sudo_dpkg_i_
- source $HOME/.SCR/lib.sh
- sudo apt-get autoclean -y
- fun_analize_command "Remove unused package from package cash"
- sudo apt clean -y
- fun_analize_command "Apt clean cash"
- sudo apt-get autoremove -y
- fun_analize_command "Remove unnecessary dependencies"
- trash-empty
- fun_analize_command "Clean Trash folder"
- cd "$HOME"
- for path in "$HOME/Desktop/" "$HOME/Downloads/" "$HOME/Telegram Desktop/"
- do
- count_files="$(find "$path" -type f | wc -l)" # get var how many files
- if (( $count_files != 0 )) # if folder consist files
- then
- fun_echo_stadia 11 0 "In $path folder is found files:"
- find "$path" -type f
- fun_echo_stadia 11 0 "Delete this folder ? (y/n)"
- read num_choice
- case "$num_choice" in
- "y" ) rm -rf "$path"
- fun_create_directory "$path" ;;
- * ) fun_echo_stadia 11 0 "Delete $path cancelled" ;;
- esac
- else
- rm -rf "$path"
- fun_create_directory "$path"
- fi
- done
- ,speech_en.sh "System clean complite"
|