a bunch of config remaps & things
This commit is contained in:
+2
-1
@@ -14,7 +14,8 @@ export DESKTOP__SFX_PATH="${HOME}/Media/sfx"
|
|||||||
export SCWRYPTS_LOG_LEVEL=0
|
export SCWRYPTS_LOG_LEVEL=0
|
||||||
case $(hostnamectl --static) in
|
case $(hostnamectl --static) in
|
||||||
( pikachu )
|
( pikachu )
|
||||||
export DESKTOP__BACKLIGHT_DEVICE=amdgpu_bl1
|
export DESKTOP__BACKLIGHT_DEVICE=xrandr-fake-brightness
|
||||||
|
export XRANDR_TARGET=DP-2
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
|||||||
@@ -1,11 +1,11 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
# do not edit; generated by scwrypts
|
# do not edit; generated by scwrypts
|
||||||
# theme : winter
|
# theme : main
|
||||||
#
|
#
|
||||||
# source this file to apply colorscheme to linux getty
|
# source this file to apply colorscheme to linux getty
|
||||||
#
|
#
|
||||||
[[ "$TERM" =~ ^linux$ ]] || return 0
|
[[ "$TERM" =~ ^linux$ ]] || return 0
|
||||||
/bin/echo -e " ]P0000505 ]P1d11455 ]P2906556 ]P300ffe7 ]P43d8890 ]P57b70af ]P650a3b5 ]P7d0f0f0 ]P8f48bae ]P9cfb8af ]PA8bfff4 ]PB1abcdd ]PC7d72fe ]PD86abb3 ]PEd0f0f0 ]PF7e707e "
|
/bin/echo -e " ]P0000505 ]P1c80064 ]P211bb98 ]P36911aa ]P42262bb ]P59922dd ]P622ccba ]P7d0f0f0 ]P8ff44ff ]P944dddd ]PAaa44ff ]PB229df6 ]PCdd88ff ]PD88ffff ]PEd0f0f0 ]PF7e707e "
|
||||||
[ ! $NO_CLEAR ] && clear
|
[ ! $NO_CLEAR ] && clear
|
||||||
return 0
|
return 0
|
||||||
sed $d
|
sed $d
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
winter
|
main
|
||||||
|
|||||||
@@ -1,14 +1,14 @@
|
|||||||
/**
|
/**
|
||||||
* do not edit; generated by scwrypts
|
* do not edit; generated by scwrypts
|
||||||
* theme : winter
|
* theme : main
|
||||||
**/
|
**/
|
||||||
|
|
||||||
*{
|
*{
|
||||||
background: #100906;
|
background: #001129;
|
||||||
foreground: #d0f0f0;
|
foreground: #d0f0f0;
|
||||||
background-alt: #007469;
|
background-alt: #9922dd;
|
||||||
foreground-alt: #d0f0f0;
|
foreground-alt: #000505;
|
||||||
selected: #d0f0f0;
|
selected: #000505;
|
||||||
active: #00ffe7;
|
active: #6911aa;
|
||||||
urgent: #d11455;
|
urgent: #c80064;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
../winter.yaml
|
../main.yaml
|
||||||
@@ -1,2 +1,2 @@
|
|||||||
[font]
|
[font]
|
||||||
size = 9.9
|
size = 9
|
||||||
|
|||||||
@@ -10,7 +10,11 @@ SCWRYPTS_SHORTCUT='' # CTRL + W
|
|||||||
SCWRYPTS_GENERATOR__SHOW_HELP=false
|
SCWRYPTS_GENERATOR__SHOW_HELP=false
|
||||||
|
|
||||||
[ ${DOTWRYN} ] || source "${HOME}/.zshrc"
|
[ ${DOTWRYN} ] || source "${HOME}/.zshrc"
|
||||||
SCWRYPTS_GROUP_DIRS+=("${DOTWRYN}/scwrypts")
|
SCWRYPTS_GROUP_DIRS+=(
|
||||||
|
"${DOTWRYN}/scwrypts"
|
||||||
|
"${XDG_DATA_HOME:-${HOME}/.local/share}/project-source-code/yage/home"
|
||||||
|
"${XDG_DATA_HOME:-${HOME}/.local/share}/project-source-code/yage/ttf-pokemoji"
|
||||||
|
)
|
||||||
|
|
||||||
[ -f "${XDG_CONFIG_HOME:-${HOME}/.config}/scwrypts/config.local.zsh" ] \
|
[ -f "${XDG_CONFIG_HOME:-${HOME}/.config}/scwrypts/config.local.zsh" ] \
|
||||||
&& source "${XDG_CONFIG_HOME:-${HOME}/.config}/scwrypts/config.local.zsh"
|
&& source "${XDG_CONFIG_HOME:-${HOME}/.config}/scwrypts/config.local.zsh"
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
# do not edit; generated by scwrypts
|
# do not edit; generated by scwrypts
|
||||||
# theme : winter
|
# theme : main
|
||||||
[colors.cursor]
|
[colors.cursor]
|
||||||
cursor = '0xe8fffd'
|
cursor = '0xeeddff'
|
||||||
|
|
||||||
[colors.primary]
|
[colors.primary]
|
||||||
background = '0x000505'
|
background = '0x000505'
|
||||||
@@ -9,20 +9,20 @@ foreground = '0xd0f0f0'
|
|||||||
|
|
||||||
[colors.normal]
|
[colors.normal]
|
||||||
black = '0x000505'
|
black = '0x000505'
|
||||||
red = '0xd11455'
|
red = '0xc80064'
|
||||||
green = '0x906556'
|
green = '0x11bb98'
|
||||||
yellow = '0x00ffe7'
|
yellow = '0x6911aa'
|
||||||
blue = '0x3d8890'
|
blue = '0x2262bb'
|
||||||
magenta = '0x7b70af'
|
magenta = '0x9922dd'
|
||||||
cyan = '0x50a3b5'
|
cyan = '0x22ccba'
|
||||||
white = '0xd0f0f0'
|
white = '0xd0f0f0'
|
||||||
|
|
||||||
[colors.bright]
|
[colors.bright]
|
||||||
black = '0x424253'
|
black = '0x424253'
|
||||||
red = '0xf48bae'
|
red = '0xff44ff'
|
||||||
green = '0xcfb8af'
|
green = '0x44dddd'
|
||||||
yellow = '0x8bfff4'
|
yellow = '0xaa44ff'
|
||||||
blue = '0x1abcdd'
|
blue = '0x229df6'
|
||||||
magenta = '0x7d72fe'
|
magenta = '0xdd88ff'
|
||||||
cyan = '0x86abb3'
|
cyan = '0x88ffff'
|
||||||
white = '0x7e707e'
|
white = '0x7e707e'
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
[General]
|
[General]
|
||||||
contrastOpacity=188
|
contrastOpacity=188
|
||||||
contrastUiColor=#a97f6f
|
contrastUiColor=#11bb98
|
||||||
disabledTrayIcon=false
|
disabledTrayIcon=false
|
||||||
drawColor=#d11455
|
drawColor=#d11455
|
||||||
drawFontSize=13
|
drawFontSize=13
|
||||||
@@ -11,10 +11,10 @@ saveAsFileExtension=png
|
|||||||
savePath=/home/w0ryn/Pictures/screenshot
|
savePath=/home/w0ryn/Pictures/screenshot
|
||||||
showSidePanelButton=false
|
showSidePanelButton=false
|
||||||
showStartupLaunchMessage=false
|
showStartupLaunchMessage=false
|
||||||
uiColor=#00d1bd
|
uiColor=#490099
|
||||||
undoLimit=100
|
undoLimit=100
|
||||||
uploadClientSecret=
|
uploadClientSecret=
|
||||||
userColors=picker, #8bfff4, #00ffe7, #007469, #cfb8af, #906556, #30221d, #d11455, #f48bae, #d0f0f0
|
userColors=picker, #aa44ff, #6911aa, #220069, #44dddd, #00aa79, #006922, #c80064, #ff44ff, #d0f0f0
|
||||||
|
|
||||||
[Shortcuts]
|
[Shortcuts]
|
||||||
TYPE_ARROW=E
|
TYPE_ARROW=E
|
||||||
|
|||||||
@@ -55,3 +55,8 @@
|
|||||||
|
|
||||||
[format]
|
[format]
|
||||||
signoff = true
|
signoff = true
|
||||||
|
[filter "lfs"]
|
||||||
|
clean = git-lfs clean -- %f
|
||||||
|
smudge = git-lfs smudge -- %f
|
||||||
|
process = git-lfs filter-process
|
||||||
|
required = true
|
||||||
|
|||||||
@@ -1,22 +1,22 @@
|
|||||||
# do not edit; generated by scwrypts
|
# do not edit; generated by scwrypts
|
||||||
# theme : winter
|
# theme : main
|
||||||
color0 #000505
|
color0 #000505
|
||||||
color1 #d11455
|
color1 #c80064
|
||||||
color2 #906556
|
color2 #11bb98
|
||||||
color3 #00ffe7
|
color3 #6911aa
|
||||||
color4 #3d8890
|
color4 #2262bb
|
||||||
color5 #7b70af
|
color5 #9922dd
|
||||||
color6 #50a3b5
|
color6 #22ccba
|
||||||
color7 #d0f0f0
|
color7 #d0f0f0
|
||||||
color8 #424253
|
color8 #424253
|
||||||
color9 #f48bae
|
color9 #ff44ff
|
||||||
color10 #cfb8af
|
color10 #44dddd
|
||||||
color11 #8bfff4
|
color11 #aa44ff
|
||||||
color12 #1abcdd
|
color12 #229df6
|
||||||
color13 #7d72fe
|
color13 #dd88ff
|
||||||
color14 #86abb3
|
color14 #88ffff
|
||||||
color15 #7e707e
|
color15 #7e707e
|
||||||
cursor #e8fffd
|
cursor #eeddff
|
||||||
background #000505
|
background #000505
|
||||||
foreground #d0f0f0
|
foreground #d0f0f0
|
||||||
selection_background #
|
selection_background #
|
||||||
|
|||||||
@@ -1,23 +1,23 @@
|
|||||||
# do not edit; generated by scwrypts
|
# do not edit; generated by scwrypts
|
||||||
# theme : winter
|
# theme : main
|
||||||
[colors]
|
[colors]
|
||||||
background = #000505
|
background = #000505
|
||||||
foreground = #d0f0f0
|
foreground = #d0f0f0
|
||||||
background-alt = #007469
|
background-alt = #6911aa
|
||||||
foreground-alt = #d0f0f0
|
foreground-alt = #d0f0f0
|
||||||
primary = #00ffe7
|
primary = #6911aa
|
||||||
secondary = #906556
|
secondary = #11bb98
|
||||||
alert = #d11455
|
alert = #c80064
|
||||||
disabled = #424253
|
disabled = #424253
|
||||||
|
|
||||||
primary-gradient-0 = #00a293
|
primary-gradient-0 = #420069
|
||||||
primary-gradient-1 = #00d1bd
|
primary-gradient-1 = #490099
|
||||||
primary-gradient-2 = #00ffe7
|
primary-gradient-2 = #6911aa
|
||||||
primary-gradient-3 = #2effec
|
primary-gradient-3 = #8811cc
|
||||||
primary-gradient-4 = #5dfff0
|
primary-gradient-4 = #9922dd
|
||||||
|
|
||||||
secondary-gradient-0 = #503830
|
secondary-gradient-0 = #006942
|
||||||
secondary-gradient-1 = #704f43
|
secondary-gradient-1 = #009949
|
||||||
secondary-gradient-2 = #906556
|
secondary-gradient-2 = #00aa79
|
||||||
secondary-gradient-3 = #a97f6f
|
secondary-gradient-3 = #11bb98
|
||||||
secondary-gradient-4 = #bc9b8f
|
secondary-gradient-4 = #22ccba
|
||||||
|
|||||||
@@ -6,8 +6,8 @@ for PREFERRED_TERMINAL in \
|
|||||||
kitty \
|
kitty \
|
||||||
;
|
;
|
||||||
do
|
do
|
||||||
command -v $PREFERRED_TERMINAL &>/dev/null \
|
command -v ${PREFERRED_TERMINAL} &>/dev/null \
|
||||||
&& export TERMINAL="$(which $PREFERRED_TERMINAL)" \
|
&& export TERMINAL="$(which ${PREFERRED_TERMINAL})" \
|
||||||
&& break
|
&& break
|
||||||
done
|
done
|
||||||
unset PREFERRED_TERMINAL
|
unset PREFERRED_TERMINAL
|
||||||
@@ -21,22 +21,22 @@ for PREFERRED_BROWSER in \
|
|||||||
google-chrome \
|
google-chrome \
|
||||||
;
|
;
|
||||||
do
|
do
|
||||||
command -v $PREFERRED_BROWSER &>/dev/null \
|
command -v ${PREFERRED_BROWSER} &>/dev/null \
|
||||||
&& export BROWSER="$(which $PREFERRED_BROWSER)" \
|
&& export BROWSER="$(which ${PREFERRED_BROWSER})" \
|
||||||
&& break
|
&& break
|
||||||
done
|
done
|
||||||
unset PREFERRED_BROWSER
|
unset PREFERRED_BROWSER
|
||||||
|
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
for XINITRC_FILE in $(find /etc/X11/xinit/xinitrc.d | sort); do source "$XINITRC_FILE"; done
|
for XINITRC_FILE in $(find /etc/X11/xinit/xinitrc.d | sort); do source "${XINITRC_FILE}"; done
|
||||||
unset XINITRC_FILE
|
unset XINITRC_FILE
|
||||||
|
|
||||||
[ -f "$HOME/.config/X11/xmodmap" ] \
|
[ -f "${XDG_CONFIG_HOME:=${HOME}/.config}/X11/xmodmap" ] \
|
||||||
&& xmodmap "$HOME/.config/X11/xmodmap"
|
&& xmodmap "${XDG_CONFIG_HOME}/X11/xmodmap"
|
||||||
|
|
||||||
[ -f "$HOME/.config/X11/xkeymap" ] \
|
[ -f "${XDG_CONFIG_HOME}/X11/xkeymap" ] \
|
||||||
&& xkbcomp "$HOME/.config/X11/xkeymap" ${DISPLAY}
|
&& xkbcomp "${XDG_CONFIG_HOME}/X11/xkeymap" ${DISPLAY}
|
||||||
|
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
|
|||||||
@@ -14,6 +14,10 @@ MAIN() {
|
|||||||
command -v ${UTIL} >/dev/null 2>&1 && break
|
command -v ${UTIL} >/dev/null 2>&1 && break
|
||||||
done
|
done
|
||||||
|
|
||||||
|
case ${DESKTOP__BACKLIGHT_DEVICE} in
|
||||||
|
( xrandr-fake-brightness ) UTIL=xrandr ;;
|
||||||
|
esac
|
||||||
|
|
||||||
[[ ${UTIL} =~ ^enlighten$ ]] && {
|
[[ ${UTIL} =~ ^enlighten$ ]] && {
|
||||||
CURRENT_PERCENT=$(BACKLIGHT_DEVICE=${DESKTOP__BACKLIGHT_DEVICE} enlighten | sed 's/.*(//;s/%.*//')
|
CURRENT_PERCENT=$(BACKLIGHT_DEVICE=${DESKTOP__BACKLIGHT_DEVICE} enlighten | sed 's/.*(//;s/%.*//')
|
||||||
[[ ${CURRENT_PERCENT} -gt 60 ]] && DELTA=40
|
[[ ${CURRENT_PERCENT} -gt 60 ]] && DELTA=40
|
||||||
@@ -22,6 +26,22 @@ MAIN() {
|
|||||||
[[ ${CURRENT_PERCENT} -le 10 ]] && DELTA=5
|
[[ ${CURRENT_PERCENT} -le 10 ]] && DELTA=5
|
||||||
}
|
}
|
||||||
|
|
||||||
|
local UP DOWN
|
||||||
|
[[ ${UTIL} =~ ^xrandr$ ]] && {
|
||||||
|
[[ "${XRANDR_TARGET[@]}" ]] \
|
||||||
|
|| XRANDR_TARGET=$(xrandr | grep ' connected' | awk '{print $1;}')
|
||||||
|
|
||||||
|
CURRENT_BRIGHTNESS=$(xrandr --verbose | grep Brightness | awk '{print $2;}' | head -n1)
|
||||||
|
|
||||||
|
[[ ${CURRENT_BRIGHTNESS} -gt 0.80 ]] && { UP=1.00; DOWN=0.80; }
|
||||||
|
[[ ${CURRENT_BRIGHTNESS} -le 0.80 ]] && { UP=1.00; DOWN=0.60; }
|
||||||
|
[[ ${CURRENT_BRIGHTNESS} -le 0.60 ]] && { UP=0.80; DOWN=0.40; }
|
||||||
|
[[ ${CURRENT_BRIGHTNESS} -le 0.40 ]] && { UP=0.60; DOWN=0.20; }
|
||||||
|
[[ ${CURRENT_BRIGHTNESS} -le 0.20 ]] && { UP=0.40; DOWN=0.10; }
|
||||||
|
[[ ${CURRENT_BRIGHTNESS} -le 0.10 ]] && { UP=0.20; DOWN=0.05; }
|
||||||
|
[[ ${CURRENT_BRIGHTNESS} -le 0.05 ]] && { UP=0.10; DOWN=0.05; }
|
||||||
|
}
|
||||||
|
|
||||||
case $1 in
|
case $1 in
|
||||||
up )
|
up )
|
||||||
case ${UTIL} in
|
case ${UTIL} in
|
||||||
@@ -32,6 +52,8 @@ MAIN() {
|
|||||||
[[ ${CURRENT_PERCENT} -ge 99 ]] && notify.status 'at maximum brightness' && exit 0
|
[[ ${CURRENT_PERCENT} -ge 99 ]] && notify.status 'at maximum brightness' && exit 0
|
||||||
BACKLIGHT_DEVICE=${DESKTOP__BACKLIGHT_DEVICE} enlighten +${DELTA}%
|
BACKLIGHT_DEVICE=${DESKTOP__BACKLIGHT_DEVICE} enlighten +${DELTA}%
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
( xrandr ) xrandr --output ${XRANDR_TARGET} --brightness ${UP} ;;
|
||||||
esac
|
esac
|
||||||
;;
|
;;
|
||||||
down )
|
down )
|
||||||
@@ -50,6 +72,8 @@ MAIN() {
|
|||||||
[[ ${CURRENT_PERCENT} -le 2 ]] && ARGS='=1%' || ARGS="-${DELTA}%"
|
[[ ${CURRENT_PERCENT} -le 2 ]] && ARGS='=1%' || ARGS="-${DELTA}%"
|
||||||
BACKLIGHT_DEVICE=${DESKTOP__BACKLIGHT_DEVICE} enlighten "${ARGS}"
|
BACKLIGHT_DEVICE=${DESKTOP__BACKLIGHT_DEVICE} enlighten "${ARGS}"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
( xrandr ) xrandr --output ${XRANDR_TARGET} --brightness ${DOWN} ;;
|
||||||
esac
|
esac
|
||||||
;;
|
;;
|
||||||
set )
|
set )
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
#!/bin/zsh
|
#!/bin/zsh
|
||||||
use desktop/xorg/xrandr --group dotwryn
|
use --group dotwryn desktop/xorg/xrandr
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
MAIN() {
|
MAIN() {
|
||||||
|
|||||||
@@ -12,4 +12,4 @@ MEMO__DIR="$SCWRYPTS_DATA_PATH/memo"
|
|||||||
|
|
||||||
[ ! -d $MEMO__DIR ] && mkdir -p $MEMO__DIR
|
[ ! -d $MEMO__DIR ] && mkdir -p $MEMO__DIR
|
||||||
|
|
||||||
MEMO__LIST_ALL() { ls $MEMO__DIR | sed "s/\.$MEMO__FILETYPE$//" | sort; }
|
${scwryptsmodule}.list-all() { ls $MEMO__DIR | sed "s/\.$MEMO__FILETYPE$//" | sort; }
|
||||||
|
|||||||
@@ -1,14 +1,16 @@
|
|||||||
#!/usr/bin/env zsh
|
#!/usr/bin/env zsh
|
||||||
use office/memo
|
use --group dotwryn office/memo
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
MAIN() {
|
MAIN() {
|
||||||
local MEMO_NAME=$(MEMO__LIST_ALL | FZF_USER_INPUT 'select/create a memo')
|
local MEMO_NAME=$(dotwryn.office.memo.list-all | utils.fzf.user-input 'select/create a memo')
|
||||||
[ ! "$MEMO_NAME" ] && user.abort
|
[ "${MEMO_NAME}" ] || utils.abort
|
||||||
|
|
||||||
MEMO_FILE="$MEMO__DIR/$MEMO_NAME.$MEMO__FILETYPE"
|
echo.debug -v MEMO_NAME
|
||||||
|
|
||||||
[ ! -f $MEMO_FILE ] && {
|
MEMO_FILE="${MEMO__DIR}/${MEMO_NAME}.${MEMO__FILETYPE}"
|
||||||
|
|
||||||
|
[ ! -f ${MEMO_FILE} ] && {
|
||||||
echo.status "creating memo '$MEMO_NAME'"
|
echo.status "creating memo '$MEMO_NAME'"
|
||||||
echo "# $MEMO_NAME" > "$MEMO_FILE" \
|
echo "# $MEMO_NAME" > "$MEMO_FILE" \
|
||||||
&& echo.success "created memo '$MEMO_NAME'" \
|
&& echo.success "created memo '$MEMO_NAME'" \
|
||||||
@@ -19,5 +21,5 @@ MAIN() {
|
|||||||
DATESTRING="## $(date '+%A, %B %-d, %Y')"
|
DATESTRING="## $(date '+%A, %B %-d, %Y')"
|
||||||
grep -q "$DATESTRING" "$MEMO_FILE" || echo "$DATESTRING" >> "$MEMO_FILE"
|
grep -q "$DATESTRING" "$MEMO_FILE" || echo "$DATESTRING" >> "$MEMO_FILE"
|
||||||
|
|
||||||
utils.io.edit "$MEMO_FILE"
|
utils.io.edit "${MEMO_FILE}"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
#!/bin/zsh
|
#!/bin/zsh
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
use system --group dotwryn
|
use --group dotwryn system
|
||||||
|
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
|
|||||||
@@ -4,12 +4,12 @@
|
|||||||
|
|
||||||
|
|
||||||
# symlinks to source-controlled configurations
|
# symlinks to source-controlled configurations
|
||||||
use system/symlinks --group dotwryn
|
use --group dotwryn system/symlinks
|
||||||
|
|
||||||
|
|
||||||
# compile source-controlled terminfo files
|
# compile source-controlled terminfo files
|
||||||
use system/terminfo --group dotwryn
|
use --group dotwryn system/terminfo
|
||||||
|
|
||||||
|
|
||||||
# common argument parsing
|
# common argument parsing
|
||||||
use system/zshparse --group dotwryn
|
use --group dotwryn system/zshparse
|
||||||
|
|||||||
@@ -6,3 +6,7 @@ media-sync:
|
|||||||
.ENVIRONMENT: MEDIA_SYNC__S3_BUCKET
|
.ENVIRONMENT: MEDIA_SYNC__S3_BUCKET
|
||||||
targets:
|
targets:
|
||||||
.ENVIRONMENT: MEDIA_SYNC__TARGETS
|
.ENVIRONMENT: MEDIA_SYNC__TARGETS
|
||||||
|
|
||||||
|
mscore:
|
||||||
|
scores-path:
|
||||||
|
.ENVIRONMENT: MSCORE__SCORES_PATH
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
#!/usr/bin/env zsh
|
#!/usr/bin/env zsh
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
use audio/play-sfx --group media
|
use --group media audio/play-sfx
|
||||||
|
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
#!/bin/zsh
|
#!/bin/zsh
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
use audio/pulseaudio/volume --group media
|
use --group media audio/pulseaudio/volume
|
||||||
|
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
use notify
|
use notify
|
||||||
use audio/play-sfx --group media
|
use --group media audio/play-sfx
|
||||||
|
|
||||||
DEPENDENCIES+=(pactl)
|
DEPENDENCIES+=(pactl)
|
||||||
|
|
||||||
|
|||||||
@@ -4,11 +4,11 @@
|
|||||||
|
|
||||||
|
|
||||||
# synchronize cloud media with configured targets
|
# synchronize cloud media with configured targets
|
||||||
use cloud/synchronize --group media
|
use --group media cloud/synchronize
|
||||||
|
|
||||||
# synchronize cloud media with a specific target
|
# synchronize cloud media with a specific target
|
||||||
use cloud/synchronize-target --group media
|
use --group media cloud/synchronize-target
|
||||||
|
|
||||||
|
|
||||||
# common parsers
|
# common parsers
|
||||||
use cloud/zshparse --group media
|
use --group media cloud/zshparse
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
#!/usr/bin/env zsh
|
#!/usr/bin/env zsh
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
use cloud --group media
|
use --group media cloud
|
||||||
|
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
REQUIRED_ENV+=(MEDIA_SYNC__S3_BUCKET)
|
REQUIRED_ENV+=(MEDIA_SYNC__S3_BUCKET)
|
||||||
|
|
||||||
use cloud/aws
|
use cloud/aws
|
||||||
use cloud/zshparse/actions --group media
|
use --group media cloud/zshparse/actions
|
||||||
|
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
|
|||||||
@@ -2,8 +2,8 @@
|
|||||||
|
|
||||||
REQUIRED_ENV+=(MEDIA_SYNC__TARGETS)
|
REQUIRED_ENV+=(MEDIA_SYNC__TARGETS)
|
||||||
|
|
||||||
use cloud/synchronize-target --group media
|
use --group media cloud/synchronize-target
|
||||||
use cloud/zshparse/actions --group media
|
use --group media cloud/zshparse/actions
|
||||||
|
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
|
|||||||
@@ -2,4 +2,4 @@
|
|||||||
# common parsers for cloud media synchronization
|
# common parsers for cloud media synchronization
|
||||||
#
|
#
|
||||||
|
|
||||||
use cloud/zshparse/actions --group media
|
use --group media cloud/zshparse/actions
|
||||||
|
|||||||
@@ -5,5 +5,5 @@
|
|||||||
|
|
||||||
DEPENDENCIES+=(ffmpeg)
|
DEPENDENCIES+=(ffmpeg)
|
||||||
|
|
||||||
use ffmpeg/get-audio-clip-from-video --group media
|
use --group media ffmpeg/get-audio-clip-from-video
|
||||||
use ffmpeg/get-video-length-seconds --group media
|
use --group media ffmpeg/get-video-length-seconds
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
DEPENDENCIES+=(ffmpeg)
|
DEPENDENCIES+=(ffmpeg)
|
||||||
|
|
||||||
use ffmpeg/get-video-length-seconds --group media
|
use --group media ffmpeg/get-video-length-seconds
|
||||||
|
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,9 @@
|
|||||||
|
#####################################################################
|
||||||
|
|
||||||
|
DEPENDENCIES+=(mscore)
|
||||||
|
|
||||||
|
#####################################################################
|
||||||
|
|
||||||
|
${scwryptsmodule}.cli() {
|
||||||
|
QT_QPA_PLATFORM=offscreen mscore $@
|
||||||
|
}
|
||||||
@@ -0,0 +1,14 @@
|
|||||||
|
#
|
||||||
|
# render / upload tools for MuseScore
|
||||||
|
#
|
||||||
|
|
||||||
|
# context wrapper for MuseScore CLI
|
||||||
|
use --group media mscore/cli
|
||||||
|
eval "${scwryptsmodule}() { ${scwryptsmodule}.cli \$@; }"
|
||||||
|
|
||||||
|
# render pdf from MuseScore file
|
||||||
|
use --group media mscore/render
|
||||||
|
|
||||||
|
|
||||||
|
# common parsers
|
||||||
|
use --group media mscore/zshparse
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
#####################################################################
|
||||||
|
|
||||||
|
use --group media mscore/cli
|
||||||
|
use --group media mscore/zshparse/filename
|
||||||
|
|
||||||
|
#####################################################################
|
||||||
|
|
||||||
|
|
||||||
|
${scwryptsmodule}.pdf() {
|
||||||
|
eval "$(USAGE.reset)"
|
||||||
|
|
||||||
|
local \
|
||||||
|
MSCORE_FILENAME \
|
||||||
|
PARSERS=(
|
||||||
|
media.mscore.zshparse.filename
|
||||||
|
)
|
||||||
|
|
||||||
|
eval "$ZSHPARSEARGS"
|
||||||
|
|
||||||
|
##########################################
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,72 @@
|
|||||||
|
REQUIRED_ENV+=(MSCORE__SCORES_PATH)
|
||||||
|
|
||||||
|
${scwryptsmodule}() {
|
||||||
|
# local MSCORE_FILENAME
|
||||||
|
local PARSED=0
|
||||||
|
|
||||||
|
case $1 in
|
||||||
|
( --filename )
|
||||||
|
PARSED=2
|
||||||
|
MSCORE_FILENAME="$2"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
return $PARSED
|
||||||
|
}
|
||||||
|
|
||||||
|
#####################################################################
|
||||||
|
|
||||||
|
${scwryptsmodule}.usage() {
|
||||||
|
USAGE__options+="
|
||||||
|
--filename <string> a valid mscore filename
|
||||||
|
"
|
||||||
|
}
|
||||||
|
|
||||||
|
${scwryptsmodule}.validate() {
|
||||||
|
case "${MSCORE_FILENAME}" in
|
||||||
|
( '' )
|
||||||
|
MSCORE__SCORES_PATH
|
||||||
|
MSCORE_FILENAME="$(cd "${MSCORE__SCORES_PATH}"; find . -type f | grep '\.msc[zx]$' | utils.fzf 'select a score')"
|
||||||
|
|
||||||
|
[ "${MSCORE_FILENAME}" ] && [ -f "${MSCORE__SCORES_PATH}/${MSCORE_FILENAME}" ] \
|
||||||
|
|| ERROR "invalid score '${MSCORE_FILENAME}'"
|
||||||
|
|
||||||
|
MSCORE_FILENAME="${MSCORE__SCORES_PATH}/${MSCORE_FILENAME}"
|
||||||
|
;;
|
||||||
|
|
||||||
|
( * )
|
||||||
|
[ -f "${MSCORE_FILENAME}" ] \
|
||||||
|
|| ERROR "no score '${MSCORE_FILENAME}' exists"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
[[ ${ERRORS} -eq 0 ]] || return
|
||||||
|
|
||||||
|
local TEMP_PATH="${SCWRYPTS_TEMP_PATH}/mscore"
|
||||||
|
local MSCORE_BASENAME="$(basename -- ${MSCORE_FILENAME} | sed 's/\.[^.]*$//')"
|
||||||
|
local TEMP_FILE="${TEMP_PATH}/${MSCORE_BASENAME}.mscx"
|
||||||
|
|
||||||
|
case "${MSCORE_FILENAME}" in
|
||||||
|
( *.mscz )
|
||||||
|
mkdir -p "${TEMP_PATH}/zip"
|
||||||
|
{
|
||||||
|
cp "${MSCORE_FILENAME}" "${TEMP_PATH}/zip/${MSCORE_BASENAME}.zip"
|
||||||
|
cd "${TEMP_PATH}/zip"
|
||||||
|
unzip "${MSCORE_BASENAME}.zip"
|
||||||
|
cp "./${MSCORE_BASENAME}.mscx" "${TEMP_FILE}"
|
||||||
|
}
|
||||||
|
;;
|
||||||
|
|
||||||
|
( *.mscx )
|
||||||
|
mkdir -p "${TEMP_PATH}"
|
||||||
|
cp "${MSCORE_FILENAME}" "${TEMP_FILE}"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
[ -f "${TEMP_FILE}" ] \
|
||||||
|
&& MSCORE_FILENAME="${TEMP_FILE}" \
|
||||||
|
|| ERROR "failed to extract '${TEMP_FILE}'" \
|
||||||
|
|| MSCORE_FILENAME='' \
|
||||||
|
;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
#
|
||||||
|
# common parsers for MuseScore actions
|
||||||
|
#
|
||||||
|
|
||||||
|
# helpers to get/select filenames for MuseScore
|
||||||
|
use --group media mscore/zshparse/filename
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
#!/bin/zsh
|
#!/bin/zsh
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
use youtube --group media
|
use --group media youtube
|
||||||
|
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
use youtube/yt-dlp --group media
|
use --group media youtube/yt-dlp
|
||||||
use youtube/get-filename --group media
|
use --group media youtube/get-filename
|
||||||
use youtube/get-download-path --group media
|
use --group media youtube/get-download-path
|
||||||
|
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
#!/bin/zsh
|
#!/bin/zsh
|
||||||
|
|
||||||
use ffmpeg/get-audio-clip-from-video --group media
|
use --group media ffmpeg/get-audio-clip-from-video
|
||||||
use youtube/get-download-path --group media
|
use --group media youtube/get-download-path
|
||||||
|
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
use youtube/yt-dlp --group media
|
use --group media youtube/yt-dlp
|
||||||
|
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
|
|||||||
@@ -4,12 +4,12 @@
|
|||||||
|
|
||||||
|
|
||||||
# download a youtube video by URL
|
# download a youtube video by URL
|
||||||
use youtube/download --group media
|
use --group media youtube/download
|
||||||
|
|
||||||
|
|
||||||
# show fully-qualified path to downloads
|
# show fully-qualified path to downloads
|
||||||
use youtube/get-download-path --group media
|
use --group media youtube/get-download-path
|
||||||
|
|
||||||
|
|
||||||
# interact with yt-dlp directly
|
# interact with yt-dlp directly
|
||||||
use youtube/yt-dlp --group media
|
use --group media youtube/yt-dlp
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
use youtube/get-download-path --group media
|
use --group media youtube/get-download-path
|
||||||
|
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
#!/bin/zsh
|
#!/bin/zsh
|
||||||
use bastion --group remote
|
use --group remote bastion
|
||||||
use config --group remote
|
use --group remote config
|
||||||
#####################################################################
|
#####################################################################
|
||||||
|
|
||||||
USAGE__options="
|
USAGE__options="
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
#!/bin/zsh
|
#!/bin/zsh
|
||||||
use bastion --group remote
|
use --group remote bastion
|
||||||
use config --group remote
|
use --group remote config
|
||||||
|
|
||||||
DEPENDENCIES+=(timeout ssh)
|
DEPENDENCIES+=(timeout ssh)
|
||||||
#####################################################################
|
#####################################################################
|
||||||
@@ -24,7 +24,7 @@ USAGE__description='
|
|||||||
|
|
||||||
MAIN() {
|
MAIN() {
|
||||||
local CONNECTION_STRING REMOTE_NAME
|
local CONNECTION_STRING REMOTE_NAME
|
||||||
local TIMEOUT_SECONDS=3
|
local TIMEOUT_SECONDS=5
|
||||||
local COMMAND='echo OK &>/dev/null'
|
local COMMAND='echo OK &>/dev/null'
|
||||||
local USE_BASTION
|
local USE_BASTION
|
||||||
while [[ $# -gt 0 ]]
|
while [[ $# -gt 0 ]]
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
# must work as a standalone zsh script
|
# must work as a standalone zsh script
|
||||||
#
|
#
|
||||||
eval "$(scwrypts --config)" \
|
eval "$(scwrypts --config)" \
|
||||||
&& use omni --group remote \
|
&& use --group omni \
|
||||||
&& utils.check-environment \
|
&& utils.check-environment \
|
||||||
|| { echo 'scwrypts config error; aborting' >&2; sleep 5; return 1; }
|
|| { echo 'scwrypts config error; aborting' >&2; sleep 5; return 1; }
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,6 @@
|
|||||||
|
[[ ${SSH_AUTH_SOCK} ]] || {
|
||||||
find "${HOME}/.1password/agent.sock" &>/dev/null \
|
find "${HOME}/.1password/agent.sock" &>/dev/null \
|
||||||
&& export SSH_AUTH_SOCK="${HOME}/.1password/agent.sock"
|
&& export SSH_AUTH_SOCK="${HOME}/.1password/agent.sock"
|
||||||
|
}
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
|
|||||||
Reference in New Issue
Block a user