Skip to content

Instantly share code, notes, and snippets.

View HansCz's full-sized avatar

Hans Czajkowski Jørgensen HansCz

  • The Danish Board of Technology Foundation
View GitHub Profile
; Global settings for redshift
[redshift]
; Set the day and night screen temperatures
temp-day=5700
temp-night=3000
; Disable the smooth fade between temperatures when Redshift starts and stops.
; 0 will cause an immediate change between screen temperatures.
; 1 will gradually apply the new screen temperature over a couple of seconds.
fade=1
@HansCz
HansCz / journal-excerpt.txt
Last active January 28, 2019 02:48
The 'blank monitor at boot'-issue
- Trying to figure out how lightdm gets started
[... huge section with all the legwork omitted. Here's my summary]
1. The systemd boot process begins
2. At some point, the conditions in the systemd unit lightdm.service are met.
/etc/systemd/system/display-manager.service:
...
@HansCz
HansCz / clear_synergy_settings.sh
Last active August 15, 2017 10:15
Clear synergy settings (bash)
rm ~/Library/Preferences/com.http-symless-com.Synergy.plist
rm -rf ~/Library/Synergy/
killall -u $USER cfprefsd
echo "finish removing Synergy settings"
@HansCz
HansCz / gist:5e5708d654e003938c3c
Created March 3, 2015 14:12
Wget an entire site recursively
wget \
--recursive \
--no-clobber \
--page-requisites \
--html-extension \
--convert-links \
--restrict-file-names=windows \
--domains the-site-to-get.com \
--no-parent \
-w 2 \
@HansCz
HansCz / hide_iterm_icon.sh
Last active August 29, 2015 14:02 — forked from maxkandler/gist:5233150
Hide ITerm 2 dock icon
/usr/libexec/PlistBuddy -c 'Add :LSUIElement bool true' /Applications/iTerm.app/Contents/Info.plist
@HansCz
HansCz / gist:f3ceb5948bd7fcfcc2bd
Created May 31, 2014 12:49
git (Bash) - Cherry pick from another repository
git --git-dir=../other-repo-directory/.git format-patch -k -1 --stdout <insert commit hash> | git am -3 -k
@HansCz
HansCz / brew --config
Created December 7, 2013 18:14
brew php55 error report
HOMEBREW_VERSION: 0.9.5
ORIGIN: https://github.com/mxcl/homebrew.git
HEAD: 57560ed57f49fa76a950e01018f736dfaf959725
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
CPU: dual-core 64-bit penryn
OS X: 10.6.8-i386
Xcode: 3.2.6
GCC-4.0: build 5494
GCC-4.2: build 5666
/**
* Cafe
*/
@import url(http://fonts.googleapis.com/css?family=Quicksand|Josefin+Sans:300,400);
body {
margin: 0;
}
header {
font-family: 'Josefin Sans', sans-serif;
@HansCz
HansCz / move_dirs.sh
Last active December 15, 2015 17:39
Rsync (Bash) - Move a tree of directories somewhere else
# ref: http://superuser.com/a/37153
rsync -av --remove-source-files src/ dest/