update
This commit is contained in:
parent
3f4cf44cfd
commit
823b33e064
25
mybashrc
25
mybashrc
|
@ -94,11 +94,11 @@ ffmpeg_start_time() {
|
|||
else
|
||||
FFMPEG_ARGS="$1 -i \"$2\""
|
||||
if [ -n "$3" ]; then
|
||||
FFMPEG_ARGS="$FFMPEG_ARGS -time $3 -c copy -movflags +faststart ${2%.mp4}-output.mp4"
|
||||
FFMPEG_ARGS="$FFMPEG_ARGS -t $3 -c copy -movflags +faststart ${2%.mp4}-output.mp4"
|
||||
else
|
||||
FFMPEG_ARGS="$FFMPEG_ARGS -c copy -movflags +faststart ${2%.mp4}-output.mp4"
|
||||
fi
|
||||
/usr/bin/ffmpeg -ss "$FFMPEG_ARGS"
|
||||
ffmpeg -ss "$FFMPEG_ARGS"
|
||||
fi
|
||||
}
|
||||
|
||||
|
@ -143,7 +143,7 @@ MAINTENANCE_APT() {
|
|||
CGREEN="${CSI}1;32m"
|
||||
|
||||
if [ "$(id -u)" = "0" ] || [ -n "$IS_SUDOERS" ]; then
|
||||
|
||||
export DEBIAN_FRONTEND=noninteractive
|
||||
echo -e "${CGREEN}#############################################${CEND}"
|
||||
echo -e ' APT UPDATE '
|
||||
echo -e "${CGREEN}#############################################${CEND}"
|
||||
|
@ -151,15 +151,15 @@ MAINTENANCE_APT() {
|
|||
echo -e "${CGREEN}#############################################${CEND}"
|
||||
echo -e ' APT FULL-UPGRADE '
|
||||
echo -e "${CGREEN}#############################################${CEND}"
|
||||
DEBIAN_FRONTEND=noninteractive $NEED_SUDO apt-get -o Dpkg::Options::="--force-confmiss" -o Dpkg::Options::="--force-confold" -y dist-upgrade
|
||||
$NEED_SUDO apt-get -o Dpkg::Options::="--force-confmiss" -o Dpkg::Options::="--force-confold" -y dist-upgrade
|
||||
echo -e "${CGREEN}#############################################${CEND}"
|
||||
echo -e ' APT-GET AUTOREMOVE '
|
||||
echo -e "${CGREEN}#############################################${CEND}"
|
||||
DEBIAN_FRONTEND=noninteractive $NEED_SUDO apt-get -o Dpkg::Options::="--force-confmiss" -o Dpkg::Options::="--force-confold" -y --purge autoremove
|
||||
$NEED_SUDO apt-get -o Dpkg::Options::="--force-confmiss" -o Dpkg::Options::="--force-confold" -y --purge autoremove
|
||||
echo -e "${CGREEN}#############################################${CEND}"
|
||||
echo -e ' APT AUTOCLEAN '
|
||||
echo -e "${CGREEN}#############################################${CEND}"
|
||||
DEBIAN_FRONTEND=noninteractive $NEED_SUDO apt-get -o Dpkg::Options::="--force-confmiss" -o Dpkg::Options::="--force-confold" -y autoclean
|
||||
$NEED_SUDO apt-get -o Dpkg::Options::="--force-confmiss" -o Dpkg::Options::="--force-confold" -y autoclean
|
||||
$NEED_SUDO apt-get -y clean
|
||||
## clean packages in deinstall state
|
||||
DEINSTALLED=$($NEED_SUDO dpkg --get-selections | grep deinstall | cut -f1)
|
||||
|
@ -521,6 +521,16 @@ _PWGEN() {
|
|||
pwgen -s 24 1
|
||||
}
|
||||
|
||||
_FD() {
|
||||
if [ -z "$(command -v fd)" ]; then
|
||||
echo "downloading fd ..."
|
||||
wget -qO https://github.com/sharkdp/fd/releases/download/v7.3.0/fd-musl_7.3.0_amd64.deb -O /tmp/fd.deb > /dev/null
|
||||
echo "installing fd ..."
|
||||
dpkg -i /tmp/fd.deb && rm /tmp/db.deb > /dev/null
|
||||
fi
|
||||
fd "$@"
|
||||
}
|
||||
|
||||
# enable color support of ls and also add handy aliases
|
||||
# some more ls aliases
|
||||
#alias wp='/usr/bin/wp --allow-root'
|
||||
|
@ -587,4 +597,5 @@ alias apt-repo-ubuntu=_APT_REPO_UBUNTU
|
|||
alias apt-bionic-kernel=_APT_BIONIC_KERNEL
|
||||
alias ufw-minimal=_UFW_MINIMAL
|
||||
alias ssh-secure=_SSH_SECURE
|
||||
alias passwdgen=_PWGEN
|
||||
alias passwdgen=_PWGEN
|
||||
alias pip='python3 -m pip'
|
2
setup.sh
2
setup.sh
|
@ -30,7 +30,7 @@
|
|||
|
||||
# clone mybashrc or update it
|
||||
if [ ! -d $HOME/.mybashrc ]; then
|
||||
git clone https://git.virtubox.net/virtubox/bashrc.git $HOME/.mybashrc
|
||||
git clone --depth=50 https://git.virtubox.net/virtubox/bashrc.git $HOME/.mybashrc
|
||||
if [ ! -d $HOME/.mybashrc/.git ]; then
|
||||
mkdir $HOME/.mybashrc
|
||||
wget -O $HOME/.mybashrc/mybashrc https://git.virtubox.net/virtubox/bashrc/raw/branch/master/mybashrc
|
||||
|
|
Loading…
Reference in New Issue