This script is provided as is, with no warranty whatsoever. There is a risk of bricking your installation if you mess around with the wrong files. Be prepared to get your hands dirty!
This script is only tested on my Pop!_OS 20.04 LTS x86_64 installation (i.e. it works on my PC). Your mileage may vary, especially if you are not using Pop.
-
Fork, clone, and
cdinto this repo. -
Run
update-alternatives --get-selections | grep gdm3-theme.gresourceto find out whichgnome-shell-theme.gresourcefile is currently being used. -
Run
cp </path/to/gnome-shell-theme.gresource/> gnome-shell-theme.gresource.backupto create your very own backup ofgnome-shell-theme.gresource. (Note: you might need to invokesudohere). -
Run
cp gnome-shell-theme.gresource.backup gnome-shell-theme.gresource; this creates a copy that we will be working with. -
Edit the
WORKDIRvariable inutils/extract.shandutils/compile.shto point to where you cloned the repo. -
At this point you would want to probably commit and push to your own fork as a safe point.
-
Run
./utils/extract.sh. This extracts thegresourcebinary into the foldertheme. -
Your entry to most edits should be on
gdm3.css(e.g. to change login screen background) and / orgnome-shell.css(e.g. to change shell related stuff). DO NOT remove the@importstatements at the top of these files! -
You can extend this to other files that you need to edit as well, by adding a
-originalsuffix to the name of the original css file, creating a new css file with the original name, and then importing the original file. Theextract.shscript assumes you will only editgdm3.cssandgnome-shell.css, so adjust accordingly if you change things. -
Once done, run
./utils/compile.shto create a newgnome-shell-theme.gresourcebinary that you should copy to wheregdm3-theme.gresourcepoints to (see step 2 of Initial setup). -
Reboot (
Alt + F2followed by typingrebootand hittingEnter) your PC for changes to take effect.
- If you brick your installation, your best bet is to probably boot from a live USB, and mount your original installation by following the steps here. Once you do so, try and undo the breaking change you introduced.