Skip to content

Instantly share code, notes, and snippets.

View dietrichm's full-sized avatar

Dietrich Moerman dietrichm

View GitHub Profile
@dietrichm
dietrichm / 99-logitech-webcam.rules
Last active November 8, 2022 10:53
Logitech C505e HD Webcam flickering
SUBSYSTEM=="video4linux", KERNEL=="video[0-9]*", ATTRS{product}=="C505e HD Webcam", ATTR{index}=="0", RUN+="/usr/bin/v4l2-ctl -d $devnode --set-ctrl=power_line_frequency=1"
@dietrichm
dietrichm / ctags.sh
Created March 17, 2020 14:19
Ctags shell function hiding "ignoring null tag in" warnings in JavaScript files
ctags() {
command ctags "$@" 2> >(
grep -Ev "^ctags: Warning: ignoring null tag in .+\.js\(line: .+\)$"
)
}
@dietrichm
dietrichm / gist:d13c41cb82c15c9d1b23
Created December 2, 2014 09:39
Git commit with ticket name
function git-ticket {
if [ $# -ge 1 ]; then
local branch=$(git rev-parse --abbrev-ref HEAD)
local ticket=${branch##*/}
local msg="${ticket}: $1"
shift
git commit -m "$msg" "$@"
else
echo "Missing comment."
fi