diff --git a/aliases b/aliases index b70f523..1d6f09a 100644 --- a/aliases +++ b/aliases @@ -100,7 +100,7 @@ alias u=umount alias testmail='echo testemail von ${USER}@${HOSTNAME} am $(date)|mail -s "TESTEMAIL ${USER}@${HOSTNAME} $(date)"' # logging -alias tailmail='sudo tail -f /var/log/mail.log /var/log/exim4/mainlog /var/log/exim4/rejectlog /var/log/exim4/paniclog' +alias tailexim='sudo tail -f /var/log/mail.log /var/log/exim4/mainlog /var/log/exim4/rejectlog /var/log/exim4/paniclog' alias tailmail='sudo journalctl -f -u exim4.service -u dovecot.service -u rspamd.service -u getmail*' alias taildemsg='sudo watch -n1 "dmesg|tail -n20"' alias tailsys='sudo tail -f /var/log/syslog /var/log/dmesg' @@ -121,6 +121,8 @@ alias unetbootin='export QT_X11_NO_MITSHM=1 unetbootin' alias vi='/usr/bin/vim' alias vlc='VDPAU_DRIVER=va_gl vlc' alias tmux='tmux -f ~/.tmux.conf' +alias youtube-dl-whole-user="youtube-dl --yes-playlist --write-description --write-info-json --write-annotations --write-all-thumbnails -f 'mp4' -o '%(uploader)s/%(playlist)s/%(playlist_index)s - %(title)s.%(ext)s' -w -c " +alias youtube-dl-whole-playlist="youtube-dl --yes-playlist --write-description --write-info-json --write-annotations --write-all-thumbnails -f 'mp4' -o '%(playlist)s/%(playlist_index)s - %(title)s.%(ext)s' -w -c " # rock64 alias rock64='sudo minicom -D /dev/ttyUSB0 --color=on' diff --git a/bashrc_add b/bashrc_add index a57c54b..c04c7f3 100755 --- a/bashrc_add +++ b/bashrc_add @@ -27,6 +27,7 @@ if [[ $- = *i* ]] ; then [ -z "${MYSHELLCONFIG_GIT_TIMEOUT+x}" ] && MYSHELLCONFIG_GIT_TIMEOUT=5s [ -z "${MYSHELLCONFIG_GIT_CHECKOUT_TIMEOUT+x}" ] && MYSHELLCONFIG_GIT_CHECKOUT_TIMEOUT=20s MYSHELLCONFIG_BASH_COMPLETION="${HOME}/${MYSHELLCONFIG_SUBPATH}/bash_completion.d" + [ -z "${MYSHELLCONFIG_GIT_SYNC+x}" ] && MYSHELLCONFIG_GIT_SYNC=true SGIT="git -C ${MYSHELLCONFIG_BASE}" export MYSHELLCONFIG_BASE MYSHELLCONFIG_LOGDIR MYSHELLCONFIG_LOGFILE SGIT MYSHELLCONFIG_VIM_PLUGINS @@ -52,22 +53,26 @@ EOF } sync_config () { - local nok="" - local gco="" - if which git >/dev/null; then - echo -n "Sync config with ${MYSHELLCONFIG_GIT_SERVER}: " 1>&2 - # MYSHELLCONFIG_GITCHECKOUTSCRIPT_OPTIONS are options for bin/git-myshellconfig-checkout - if [ -z ${MYSHELLCONFIG_GIT_CHECKOUTSCRIPT_OPTIONS+x} ]; then - gco="-h" - else - gco="$MYSHELLCONFIG_GIT_CHECKOUTSCRIPT_OPTIONS" - fi - ${MYSHELLCONFIG_BASE}/bin/git-myshellconfig-checkout ${gco}|| nok="not " 1>>"${MYSHELLCONFIG_LOGFILE}" 2>&1 - printf '%s\n' "${nok}synced" 1>&2 - [ -z "$nok" ] && mkdir -pv "${MYSHELLCONFIG_LOGDIR}" + if $MYSHELLCONFIG_GIT_SYNC; then + local nok="" + local gco="" + if which git >/dev/null; then + echo -n "Sync config with ${MYSHELLCONFIG_GIT_SERVER}: " 1>&2 + # MYSHELLCONFIG_GITCHECKOUTSCRIPT_OPTIONS are options for bin/git-myshellconfig-checkout + if [ -z ${MYSHELLCONFIG_GIT_CHECKOUTSCRIPT_OPTIONS+x} ]; then + gco="-h" + else + gco="$MYSHELLCONFIG_GIT_CHECKOUTSCRIPT_OPTIONS" + fi + ${MYSHELLCONFIG_BASE}/bin/git-myshellconfig-checkout ${gco}|| nok="not " 1>>"${MYSHELLCONFIG_LOGFILE}" 2>&1 + printf '%s\n' "${nok}synced" 1>&2 + [ -z "$nok" ] && mkdir -pv "${MYSHELLCONFIG_LOGDIR}" + else + echo "git not installed, no configuration possible, please install git" >&2 + fi else - echo "git not installed, no configuration possible, please install git" >&2 + echo "Not syncing profile in case of configuration" fi } diff --git a/bin/youtube-dl-download-or-update.sh b/bin/youtube-dl-download-or-update.sh new file mode 100755 index 0000000..4401f68 --- /dev/null +++ b/bin/youtube-dl-download-or-update.sh @@ -0,0 +1,2 @@ +#!/bin/bash +youtube-dl --write-description --write-info-json --write-annotations --write-all-thumbnails -f 'bestvideo[ext=mp4]+bestaudio[ext=m4a]/best[ext=mp4]/best' -o '%(playlist)s/%(playlist_index)s - %(title)s.%(ext)s' -c -w -a ./url diff --git a/myshell_git_sync b/myshell_git_sync index d6ff3a5..d1933fb 100644 --- a/myshell_git_sync +++ b/myshell_git_sync @@ -131,7 +131,6 @@ if ! $SSHS; then vim -c "PluginInstall" -c ":qa!" fi [ -z ${MYSHELLCONFIG_GIT_REMOTE_PUSH+x} ] || $SGIT remote set-url --push ${MYSHELLCONFIG_GIT_REMOTE_NAME} "${MYSHELLCONFIG_GIT_REMOTE_PUSH}" - # cd ${HOME} ;; *screen*) echo "I'm in sceen/tmux now" >&2