Advertisement
Guest User

Untitled

a guest
Dec 1st, 2021
134
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.58 KB | None | 0 0
  1. #!/bin/bash
  2.  
  3. # Put here the path to the theme.sh script
  4. theme_sh="$HOME/theme.sh"
  5.  
  6. # Put here the list of commands you want to have opened
  7. commands=( htop bash )
  8.  
  9. # Put here your terminal emulator if this doesn't get it right
  10. emulator="$(echo $TERM | cut -d '-' -f 1)"
  11. echo "Using $emulator"
  12.  
  13. ######################################################################
  14.  
  15. for t in $("$theme_sh" --list | sort -R); do
  16.     echo "$t"
  17.     for c in "${commands[@]}"; do
  18.         $emulator -e bash -c "\"$theme_sh\" $t && exec $c" &> /dev/null &
  19.     done
  20.     wait
  21. done 2> /dev/null
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement