dark dim fixes

This commit is contained in:
ackman678
2025-05-13 16:45:55 -04:00
parent 4353990fba
commit 623fa0f06f
3 changed files with 34 additions and 21 deletions

21
dark
View File

@@ -7,23 +7,26 @@ set -e #exit if an error
mode=${1:-"dark"} mode=${1:-"dark"}
if [[ $1 == "0" || $1 == "off" ]]; then if [[ $1 == "0" || $1 == "off" ]]; then
mode=light #mode=light
scheme=base16-atelier-dune-light.sh scheme=base16-atelier-dune-light
# scheme=base16-classic-light.sh # scheme=base16-classic-light
# scheme=base16-gruvbox-light-hard.sh # scheme=base16-gruvbox-light-hard
TaskTheme="light-256" TaskTheme="light-256"
else else
mode=dark #mode=dark
# scheme=base16-atelier-dune.sh # scheme=base16-atelier-dune
# scheme=base16-classic-dark.sh # scheme=base16-classic-dark
scheme=base16-gruvbox-dark-hard.sh scheme=base16-gruvbox-dark-hard
TaskTheme="dark-gray-256" TaskTheme="dark-gray-256"
fi fi
#if exist base16 shell color scheme, switch to scheme #if exist base16 shell color scheme, switch to scheme
ln -sf ~/.config/base16-shell/scripts/$scheme ~/.base16_theme ln -sf ~/.config/base16-shell/scripts/$scheme.sh ~/.base16_theme
sh ~/.base16_theme sh ~/.base16_theme
#if exist taskwarrior taskrc file, switch the color scheme #if exist taskwarrior taskrc file, switch the color scheme
sed -i -E "s|include /usr/share/doc/task/rc/[a-z1256-]+.theme|include /usr/share/doc/task/rc/$TaskTheme.theme|" ~/.config/task/taskrc sed -i -E "s|include /usr/share/doc/task/rc/[a-z1256-]+.theme|include /usr/share/doc/task/rc/$TaskTheme.theme|" ~/.config/task/taskrc
#if exist vimrc file, switch the color scheme
sed -i -E "s|colorscheme [a-z1256-]+|colorscheme $scheme|" ~/.vimrc

13
dim
View File

@@ -2,12 +2,17 @@
#dim: control display brightness from terminal #dim: control display brightness from terminal
#usage: dim x #usage: dim x
#where x is an integer for a new display brightness within the [min,max] range of [0,100] #where x is an integer for a new display brightness within the [min,max] range of [0,100]
#user should be part of the video user group to run this without sudo
#James B. Ackman 2019-02-06T15:55:20-08:00 #James B. Ackman 2019-02-06T15:55:20-08:00
#
# Check kernel backlight driver names on your machine: `ls -l /sys/class/backlight/*`
# e.g. acpi_video0 nv_backlight or intel_backlight
# user should be part of the video user group to run this without sudo and a udev rule with correct driver name should be added as `/etc/udev/rules.d/backlight.rules`
#ACTION=="add", SUBSYSTEM=="backlight", KERNEL=="intel_backlight", RUN+="/bin/chgrp video /sys/class/backlight/%k/brightness"
#ACTION=="add", SUBSYSTEM=="backlight", KERNEL=="intel_backlight", RUN+="/bin/chmod g+w /sys/class/backlight/%k/brightness"
# Then set following var to your backlight driver name
backlightDriver="intel_backlight"
#check kernel backlight driver names on your machine: `ls -l /sys/class/backlight/*`
#then set following var, e.g. acpi_video0 nv_backlight or intel_backlight
backlightDriver="acpi_video0"
set -e #exit if an error set -e #exit if an error
percentValue=$1 percentValue=$1

19
ws
View File

@@ -38,16 +38,21 @@ fi
# echo $workingDirectory # echo $workingDirectory
if [[ $myTerm == urxvt ]]; then if [[ $myTerm == urxvt ]]; then
#urxvt -e "dimr &" urxvt -cd $workingDirectory -title "$(basename $workingDirectory) woola" -e bash -ic "$HOME/bin/woola" &
urxvt -cd $workingDirectory -title "$(basename $workingDirectory) woola" -e bash -ic "$HOME/bin/woola" & urxvt -cd $workingDirectory -title "$(basename $workingDirectory) ranger" -e bash -ic "ranger" &
urxvt -cd $workingDirectory -title "$(basename $workingDirectory) ranger" -e bash -ic "ranger" & urxvt -cd $workingDirectory &
urxvt -cd $workingDirectory &
fi fi
if [[ $myTerm == alacritty ]]; then if [[ $myTerm == alacritty ]]; then
alacritty --working-directory $workingDirectory --title "$(basename $workingDirectory) woola" -e bash -ic "$HOME/bin/woola" & alacritty --working-directory $workingDirectory --title "$(basename $workingDirectory) fzf" -e bash -c "f && exec bash" &
alacritty --working-directory $workingDirectory --title "$(basename $workingDirectory) ranger" -e bash -ic "ranger" & alacritty --working-directory $workingDirectory --title "$(basename $workingDirectory) nnn" -e bash -c "nnn && exec bash" &
alacritty --working-directory $workingDirectory & alacritty --working-directory $workingDirectory --title "$(basename $workingDirectory) alacritty" &
alacritty --working-directory $workingDirectory --title "$(basename $workingDirectory) top" -e bash -c "top && exec bash" &
sleep 0.3
python $HOME/projects/dev/arch/ws-splithv4-33.py fzf nnn alacritty top '3'
else else
echo "edit script for compatibility with terminal" echo "edit script for compatibility with terminal"
fi fi