mirror of
https://github.com/kevinveenbirkenbach/analyze-script-collection.git
synced 2024-11-22 12:41:04 +01:00
Copied scripts from repository core system
This commit is contained in:
parent
44002ca35b
commit
40fe788f49
6
big_files.sh
Normal file
6
big_files.sh
Normal file
@ -0,0 +1,6 @@
|
||||
#!/bin/bash
|
||||
# @author Kevin Veen-Birkenbach
|
||||
# shellcheck source=/dev/null # Deactivate SC1090
|
||||
source "$(dirname "$(readlink -f "${0}")")/../../base.sh" || (echo "Loading base.sh failed." && exit 1)
|
||||
info "Searching for files which are in \"$HOME\" and bigger then 100MB..."
|
||||
find ~ -type f -size +100M -exec ls -lh {} \;
|
6
false_chown.sh
Normal file
6
false_chown.sh
Normal file
@ -0,0 +1,6 @@
|
||||
#!/bin/bash
|
||||
# @author Kevin Veen-Birkenbach
|
||||
# shellcheck source=/dev/null # Deactivate SC1090
|
||||
source "$(dirname "$(readlink -f "${0}")")/../../base.sh" || (echo "Loading base.sh failed." && exit 1)
|
||||
info "Searching for files which are in \"$HOME\" but don't belong to user \"$USER\"..."
|
||||
sudo find "$HOME" ! -user "$USER"
|
6
file_duplicates.sh
Normal file
6
file_duplicates.sh
Normal file
@ -0,0 +1,6 @@
|
||||
#!/bin/bash
|
||||
# @author Kevin Veen-Birkenbach
|
||||
# shellcheck source=/dev/null # Deactivate SC1090
|
||||
source "$(dirname "$(readlink -f "${0}")")/../../base.sh" || (echo "Loading base.sh failed." && exit 1)
|
||||
info "Checking relevant home folders for duplicated files..."
|
||||
fdupes -r "$HOME/Documents/" "$HOME/Downloads/" "$HOME/Images/" "$HOME/Desktop/" "$HOME/Music/" "$HOME/Pictures/" "$HOME/Videos"
|
6
java_versions.sh
Normal file
6
java_versions.sh
Normal file
@ -0,0 +1,6 @@
|
||||
#!/bin/bash
|
||||
# @author Kevin Veen-Birkenbach
|
||||
# shellcheck source=/dev/null # Deactivate SC1090
|
||||
source "$(dirname "$(readlink -f "${0}")")/../../base.sh" || (echo "Loading base.sh failed." && exit 1)
|
||||
info "Showing the installed Java versions..." &&
|
||||
archlinux-java status
|
5
linux_kernel.sh
Normal file
5
linux_kernel.sh
Normal file
@ -0,0 +1,5 @@
|
||||
#!/bin/bash
|
||||
# @author Kevin Veen-Birkenbach
|
||||
# shellcheck source=/dev/null # Deactivate SC1090
|
||||
source "$(dirname "$(readlink -f "${0}")")/../../base.sh" || (echo "Loading base.sh failed." && exit 1)
|
||||
info "Linux-Kernel: $(uname -r)"
|
10
not_encrypted_ssh_keys.sh
Normal file
10
not_encrypted_ssh_keys.sh
Normal file
@ -0,0 +1,10 @@
|
||||
#!/bin/bash
|
||||
# @see https://stackoverflow.com/questions/32408820/how-to-list-files-and-match-first-line-in-bash-script
|
||||
# @see https://unix.stackexchange.com/questions/298590/using-find-non-recursively
|
||||
# @see https://security.stackexchange.com/questions/129724/how-to-check-if-an-ssh-private-key-has-passphrase-or-not
|
||||
find "$HOME/.ssh" -maxdepth 1 -type f -print0 | while IFS= read -r -d $'\0' file; do
|
||||
if [[ $(head -n1 "$file") == "-----BEGIN OPENSSH PRIVATE KEY-----" ]]; then
|
||||
echo "Test file: $file"
|
||||
ssh-keygen -y -P "" -f "$file"
|
||||
fi
|
||||
done
|
Loading…
Reference in New Issue
Block a user