Skip to content

Instantly share code, notes, and snippets.

@carlos22
Created July 19, 2017 11:48
Show Gist options
  • Save carlos22/70cf3670308328048a0737a51ca16835 to your computer and use it in GitHub Desktop.
Save carlos22/70cf3670308328048a0737a51ca16835 to your computer and use it in GitHub Desktop.
this forces the usage of offline-simple.css instead of the offline.css (which is loaded via javascript in some cases, e.g. archlinux build of qtcreator)
#!/bin/bash
# this forces the usage of offline-simple.css instead of the offline.css (which is loaded via javascript in some cases, e.g. archlinux build of qtcreator)
sqlite3 /usr/share/doc/qt/qtcore.qch "Select writefile('/tmp/offline-simple.css', fd.Data) FROM FileNameTable fn, FileDataTable fd WHERE fn.fileId=fd.id AND fn.Name='style/offline-simple.css';"
sudo find /usr/share/doc/qt/ -name "*.qch" -exec sqlite3 '{}' "UPDATE FileDataTable SET Data = readfile('/tmp/offline-simple.css') WHERE id IN (SELECT FileId FROM FileNameTable WHERE Name='style/offline.css');" \;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment