Skip to content

Instantly share code, notes, and snippets.

@coderiot
coderiot / ultrapedia1.xml
Last active September 1, 2015 14:18
Ultrapedia error: Ontology property not found: dct:title
<?xml version="1.0" encoding="utf-8"?><?xml-stylesheet type="text/xsl" href="../../../stylesheets/log.xsl"?><log>
<record>
<date>2015-09-01T15:45:33</date>
<millis>1441115133535</millis>
<sequence>365007</sequence>
<logger>org.dbpedia.extraction.mappings.MappingsLoader$</logger>
<level>WARNING</level>
<class>org.dbpedia.extraction.mappings.MappingsLoader$</class>
<method>org$dbpedia$extraction$mappings$MappingsLoader$$log</method>
<thread>18462</thread>
@coderiot
coderiot / tp_wheel_emulation
Last active August 29, 2015 13:57
enable Trackpad wheel emulation (horizontal/vertical)
#!/bin/sh
xinput set-prop "TPPS/2 IBM TrackPoint" "Evdev Wheel Emulation" 1
xinput set-prop "TPPS/2 IBM TrackPoint" "Evdev Wheel Emulation Button" 2
xinput set-prop "TPPS/2 IBM TrackPoint" "Evdev Wheel Emulation Timeout" 200
xinput set-prop "TPPS/2 IBM TrackPoint" "Evdev Wheel Emulation Axes" 6 7 4 5
@coderiot
coderiot / toggle_touchpad
Created September 10, 2013 12:58
bash script toggle touchpad with xinput.
#!/bin/bash
id=$(xinput | grep TouchPad | grep -E -o "id=[[:digit:]]+" | grep -E -o "[[:digit:]]+")
if [ "$id" = "" ]
then
echo "no touchpad found."
exit 0
fi
@coderiot
coderiot / ngram.sh
Last active December 20, 2015 08:49
download and processing ngram dataset from http://books.google.com/ngrams by language and ngram length with gnu parallel.
#!/bin/bash
langs=('eng' 'eng-1M' 'eng-us' 'eng-gb' 'eng-fiction' 'chi-sim' 'fre' 'ger' 'heb' 'ita' 'rus' 'spa')
if [ $# -le 1 ]
then
echo "Usage: $0 [LANGUAGE] [N]" >&2
exit 1
fi
@coderiot
coderiot / svg2pdf
Created February 10, 2013 20:37
Vim mapping konvertiert SVG mit Inkscape zum einbinden in ein Latex Dokument.
au FileType svg map <leader>ll <CR>:!inkscape -D -z --file="%" --export-pdf="%:r".pdf --export-latex<CR><CR>