My personal collection of bash scripts I use on a regular basis.
Kinda lazy sometimes so POSIX compliance is dependant on how much effort I felt like putting in that day.
All code is licensed under the Unlicense License. (do whatever u want idc)
bash-scripts/
├── md-assets/
├── scripts/
| ├── background-picker.sh
| ├── backup.sh
| ├── cya-downloads.sh
| ├── got-git?.sh
| ├── nix-bootstrap.sh
| ├── pywal-to-spicetify.sh
| ├── random-background.sh
| ├── swww-as-theme.sh
| ├── theme-picker.sh
| ├── workspace-previews-capture.sh
| └── workspace-previews-popup.sh
├── themes/
| ├── base16-apathy.png
| ├── base16-apathy.sh
| ├── base16-ashes.png
| ├── base16-ashes.sh
| ├── base16-atalier-estuary.png
| ├── base16-atalier-estuary.sh
| ├── base16-codeschool.png
| ├── base16-codeschool.sh
| ├── base16-dracula.png
| ├── base16-dracula.sh
| ├── base16-greenscreen.png
| ├── base16-greenscreen.sh
| ├── base16-gruvbox-hard.png
| ├── base16-gruvbox-hard.sh
| ├── base16-gruvbox-medium.png
| ├── base16-gruvbox-medium.sh
| ├── base16-harmonic.png
| ├── base16-harmonic.sh
| ├── base16-icy.png
| ├── base16-icy.sh
| ├── base16-materia.png
| ├── base16-materia.sh
| ├── base16-material-palenight.png
| ├── base16-material-palenight.sh
| ├── base16-mellow-purple.png
| ├── base16-mellow-purple.sh
| ├── base16-mocha.png
| ├── base16-mocha.sh
| ├── base16-monokai.png
| ├── base16-monokai.sh
| ├── base16-nord.png
| ├── base16-nord.sh
| ├── base16-ocean.png
| ├── base16-ocean.sh
| ├── base16-rebecca.png
| ├── base16-rebecca.sh
| ├── dkeg-amiox.png
| └── dkeg-amiox.sh
├── LICENSE
└── README.md
| Script | Description | Required Dependencies |
|---|---|---|
| background-picker.sh | Background / wallpaper picker | fzf, feh, swww |
| backup.sh | Backup files and directories easily | none |
| theme-picker.sh | Theme picker | fzf, feh, pywal, themes folder |
| cya-downloads.sh | Say goodbye to dumb Downloads folders appearing in your $HOME dir | none |
| got-git?.sh | Check which dirs are git repos and show their status | git |
| nix-bootstrap.sh | Bootstrap NixOS w/ lots of options | none |
| pywal-to-spicetify.sh | Converts current Pywal theme to a Spicetify theme | pywal, spicetify, cat |
| random-background.sh | Random background / wallpaper picker | swww |
| swww-as-theme.sh | Converts current background / wallpaper into Pywal theme | current-swww-img (reference background-picker.sh, you can easily generate this yourself any way you desire) |
| workspace-previews-capture.sh | Mini workspace previews (capturer) | hyprland, hyprshot |
| workspace-previews-popup.sh | Mini workspace previews (display popups) | feh, cat, workspace-previews-capture.sh |
Tip
Read below for important information regarding each script.
Line 80 appends a file with the current selected background. This can be used for a number of things, I personally used it in the swww-as-theme.sh script.
Checks to see if I'm running the script, if not it runs in a configuration with standard xdg-usr-dirs and options designed more around general usage. Also contains a custom option so you can backup whatever you want to wherever you want.
This checks for both Capitalized (Downloads) and lowercase (downloads) folders hanging out in $HOME. Moves any files within to a desired location (with confirmation) before deleting the folders. Run manually, or schedule to run on a regular basis!
The $BASE_DIR var is used for the directory that holds the majority of your github repositories, (typically if you're a dev) and the $EXTRA_DIRS var is used for seperate directories that have git initialized at root. (Typically for dotfiles or other GNU Stow managed repositories.)
A complete NixOS system bootstrap designed to be ran post .iso installation and drive formatting.
Allows for online or even offline installation the if repo files are held on usb or already on your system.
Currently has 3 configuration profiles:
Server,Minimal, andFull.
(Ranked in order of smallest to largest final size)
And 2 hardware profiles:
Desktop,Laptop
(Does not effecthardware-configuration.nix, only additional dotfiles.)
Configures the following:
- username
- hostname
- configuration.nix
- env.systemPackages
- system.stateVersion
- dotfiles
- hyprland
- waybar
- theming
- lots n lots more
- $HOME directory
- wallpapers (optional)
Applies changes and restarts Spicetify/Spotify by default on run. This script is the reason I still theme hop. It's just fun to watch everything change when used in tandem with my other theming scripts.
Last line of the script sends a notification relaying the selected wallpaper. If you don't have a notification daemon configured, feel free to comment this line out.
This script works great in tandem with pywal-to-spicetify.sh, simply run that script on line 7 and now you're killin two birds w one stone.
Similar to background-picker.sh, Line 66 appends a file with the current selected theme. This can be used for a number of things, feel free to experiment!.
Rather than appending to a file with the selected theme, I updated it so that it runs pywal-to-spicetify.sh on line 65.
Feel free to comment this line out and modify as you please.
I missed the mini workspace preview feature of most XFCE based distros, so I made something that would work for Hyprland.
These two scripts (workspace-previews-capture.sh & workspace-previews-popup.sh) depend on each other to work properly.
Warning
If you have multiple monitors, this script will likely fuck with your copy and paste abilities. Hyprshot simply needs some extra configuration to not copy the screenshot to the system clipboard. Hope this helps!
This repository is licensed under the Unlicense License. (do whatever u want idc)
- Fork the repo
- Create a branch for your feature/fix
- Submit a pull request
all built with ❤️ by 0lswitcher
