@@ -11,9 +11,12 @@
|
||||
#
|
||||
###################################################
|
||||
|
||||
mainteiner="Marcin Woźniak"
|
||||
|
||||
function scanning(){
|
||||
EUSCAN=$(euscan --nocolor --quiet "$1")
|
||||
if [ -n "$EUSCAN" ]; then
|
||||
echo $1
|
||||
echo "=============== NOW: $(find ./* -mindepth 2 -maxdepth 2 -name ''"$1"'*.ebuild' | sort | tail -1) =================
|
||||
$(echo -e "$EUSCAN" | tail -1)"
|
||||
fi
|
||||
@@ -89,6 +92,7 @@ function main(){
|
||||
;;
|
||||
-f|--folder)
|
||||
folder "$2" | tee -a "euscan-$(date -I).log"
|
||||
|
||||
;;
|
||||
*)
|
||||
echo "No found variable"; echo; help
|
||||
|
44
.local/bin/ext
Executable file
44
.local/bin/ext
Executable file
@@ -0,0 +1,44 @@
|
||||
#!/bin/sh
|
||||
|
||||
# A general, all-purpose extraction script. Not all extraction programs here
|
||||
# are installed by LARBS automatically.
|
||||
#
|
||||
# Default behavior: Extract archive into new directory
|
||||
# Behavior with `-c` option: Extract contents into current directory
|
||||
|
||||
while getopts "hc" o; do case "${o}" in
|
||||
c) extracthere="True" ;;
|
||||
*) printf "Options:\\n -c: Extract archive into current directory rather than a new one.\\n" && exit 1 ;;
|
||||
esac done
|
||||
|
||||
if [ -z "$extracthere" ]; then
|
||||
archive="$(readlink -f "$*")" &&
|
||||
directory="$(echo "$archive" | sed 's/\.[^\/.]*$//')" &&
|
||||
mkdir -p "$directory" &&
|
||||
cd "$directory" || exit 1
|
||||
else
|
||||
archive="$(readlink -f "$(echo "$*" | cut -d' ' -f2)" 2>/dev/null)"
|
||||
fi
|
||||
|
||||
[ -z "$archive" ] && printf "Give archive to extract as argument.\\n" && exit 1
|
||||
|
||||
if [ -f "$archive" ] ; then
|
||||
case "$archive" in
|
||||
*.tar.bz2|*.tbz2) tar xvjf "$archive" ;;
|
||||
*.tar.xz) tar -xf "$archive" ;;
|
||||
*.tar.gz|*.tgz) tar xvzf "$archive" ;;
|
||||
*.lzma) unlzma "$archive" ;;
|
||||
*.bz2) bunzip2 "$archive" ;;
|
||||
*.rar) unrar x -ad "$archive" ;;
|
||||
*.gz) gunzip "$archive" ;;
|
||||
*.tar) tar xvf "$archive" ;;
|
||||
*.zip) unzip "$archive" ;;
|
||||
*.Z) uncompress "$archive" ;;
|
||||
*.7z) 7z x "$archive" ;;
|
||||
*.xz) unxz "$archive" ;;
|
||||
*.exe) cabextract "$archive" ;;
|
||||
*) printf "extract: '%s' - unknown archive method\\n" "$archive" ;;
|
||||
esac
|
||||
else
|
||||
printf "File \"%s\" not found.\\n" "$archive"
|
||||
fi
|
133
.local/bin/gfetch
Executable file
133
.local/bin/gfetch
Executable file
@@ -0,0 +1,133 @@
|
||||
#!/bin/sh
|
||||
|
||||
|
||||
# Copyright (c) 2020, XGQT
|
||||
# Licensed under the ISC License
|
||||
|
||||
# .vir.
|
||||
# ,d$$$$$$b.
|
||||
# &&&&( )&&&b
|
||||
# Q$$$$$$$$$$B
|
||||
# "$$$$$$$P
|
||||
# ,d$$$$$$P"
|
||||
# $$$$$$P
|
||||
# `Q$$P"
|
||||
|
||||
# gfetch - tiny system info for gentoo
|
||||
|
||||
# based on:
|
||||
# https://github.com/jschx/ufetch/
|
||||
|
||||
|
||||
# INFO
|
||||
|
||||
host="$(hostname 2>/dev/null)"
|
||||
cpu="$(uname -p 2>/dev/null)"
|
||||
kernel="$(uname -sr 2>/dev/null)"
|
||||
uptime="$(uptime -p 2>/dev/null | sed 's/up //')"
|
||||
shell="$(basename "${SHELL}" 2>/dev/null)"
|
||||
|
||||
if [ -f /etc/lsb-release ]
|
||||
then
|
||||
os="$(cut -d \" -f 2 < /etc/lsb-release) $(uname -m)"
|
||||
elif [ -f /etc/os-release ]
|
||||
then
|
||||
os="$(cut -d = -f 2 < /etc/os-release | sed 1q) $(uname -m)"
|
||||
else
|
||||
os="Gentoo $(uname -m)"
|
||||
fi
|
||||
|
||||
if [ -d "${EPREFIX}"/var/db/pkg ]
|
||||
then
|
||||
packages="All: $(find "${EPREFIX}"/var/db/pkg/*/* -type d | wc -l)"
|
||||
real="Real: $(find "${EPREFIX}"/var/db/pkg/*/* -type d | grep -c -v -E 'acct-group|acct-user|app-eselect|java-virtuals|media-fonts|virtual')"
|
||||
else
|
||||
packages="n/a"
|
||||
real=""
|
||||
fi
|
||||
|
||||
if [ -f "${EPREFIX}"/var/lib/portage/world ]
|
||||
then
|
||||
world="World: $(wc -l < "${EPREFIX}"/var/lib/portage/world)"
|
||||
else
|
||||
world=""
|
||||
fi
|
||||
|
||||
if [ -n "${DE}" ]
|
||||
then
|
||||
ui="${DE}"
|
||||
uitype='DE'
|
||||
elif [ -n "${WM}" ]
|
||||
then
|
||||
ui="${WM}"
|
||||
uitype='WM'
|
||||
elif [ -n "${XDG_CURRENT_DESKTOP}" ]
|
||||
then
|
||||
ui="${XDG_CURRENT_DESKTOP}"
|
||||
uitype='DE'
|
||||
elif [ -n "${DESKTOP_SESSION}" ]
|
||||
then
|
||||
ui="${DESKTOP_SESSION}"
|
||||
uitype='DE'
|
||||
elif [ -f "${HOME}/.xinitrc" ]
|
||||
then
|
||||
ui="$(tail -n 1 "${HOME}/.xinitrc" | cut -d ' ' -f 2)"
|
||||
uitype='WM'
|
||||
elif [ -f "${HOME}/.xsession" ]
|
||||
then
|
||||
ui="$(tail -n 1 "${HOME}/.xsession" | cut -d ' ' -f 2)"
|
||||
uitype='WM'
|
||||
else
|
||||
ui='unknown'
|
||||
uitype='UI'
|
||||
fi
|
||||
|
||||
|
||||
# Color Definitions
|
||||
|
||||
if [ -x "$(command -v tput)" ]; then
|
||||
bold="$(tput bold)"
|
||||
# black="$(tput setaf 0)"
|
||||
# red="$(tput setaf 1)"
|
||||
# green="$(tput setaf 2)"
|
||||
# yellow="$(tput setaf 3)"
|
||||
# blue="$(tput setaf 4)"
|
||||
magenta="$(tput setaf 5)"
|
||||
# cyan="$(tput setaf 6)"
|
||||
white="$(tput setaf 7)"
|
||||
reset="$(tput sgr0)"
|
||||
fi
|
||||
|
||||
|
||||
# Output color
|
||||
|
||||
# labels
|
||||
lc="${reset}${bold}${magenta}"
|
||||
|
||||
# user and hostname
|
||||
nc="${reset}${bold}${magenta}"
|
||||
|
||||
# info
|
||||
ic="${reset}${bold}${white}"
|
||||
|
||||
# first color
|
||||
c0="${reset}${bold}${magenta}"
|
||||
|
||||
# second color
|
||||
c1="${reset}${magenta}"
|
||||
|
||||
|
||||
# OUTPUT
|
||||
|
||||
cat <<EOF
|
||||
|
||||
${c0} .vir. ${nc}${USER}${ic}@${nc}${host}${reset}
|
||||
${c0} ,d\$\$\$\$${c1}\$\$b. ${lc}CPU: ${ic}${cpu}${reset}
|
||||
${c0} &&&&${c1}( )&&&b ${lc}OS: ${ic}${os}${reset}
|
||||
${c0} Q\$\$\$\$\$\$\$\$${c1}\$\$B ${lc}KERNEL: ${ic}${kernel}${reset}
|
||||
${c0} "\$\$\$\$\$${c1}\$\$P ${lc}UP: ${ic}${uptime}${reset}
|
||||
${c0} ,d\$\$\$\$${c1}\$\$P" ${lc}PKGS: ${ic}${packages} ${world} ${real}${reset}
|
||||
${c0} \$\$\$\$${c1}\$\$P ${lc}SHELL: ${ic}${shell}${reset}
|
||||
${c0} \`Q\$\$${c1}P" ${lc}${uitype}: ${ic}${ui}${reset}
|
||||
|
||||
EOF
|
BIN
.local/bin/rcon
Executable file
BIN
.local/bin/rcon
Executable file
Binary file not shown.
@@ -1,5 +1,7 @@
|
||||
#!/bin/bash
|
||||
AUDIO=$(pactl list sources | awk '/Name: alsa_out/{print $2}' | tail -n1)
|
||||
AUDIO=$(pactl list sources | awk '/Name: alsa_out/{print $2}' | head -n1)
|
||||
|
||||
pkill -9 xautolock; xset s 10800
|
||||
|
||||
ffmpeg \
|
||||
-f pulse \
|
||||
@@ -11,3 +13,6 @@ ffmpeg \
|
||||
-i :0 \
|
||||
-c:v h264 -crf 0 -preset ultrafast -c:a aac \
|
||||
"$HOME/screencast-$(date '+%y%m%d-%H%M-%S').mp4"
|
||||
|
||||
xset s 600&
|
||||
xautolock -time 15 -locker slock&
|
||||
|
Reference in New Issue
Block a user