This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
hhhh_transition_matrix = [ | |
0.5 0.5 0.5 0.5 0 0; | |
0.5 0 0 0 0 0; | |
0 0.5 0 0 0 0; | |
0 0 0.5 0 0 0; | |
0 0 0 0.5 0 0; | |
0 0 0 0 1 1 | |
]; | |
hhht_transition_matrix = [ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
DECODEQR_TMPDIR=$(mktemp --tmpdir=$TMPDIR -d) | |
if [ $? -eq 0 -a ! -z "$DECODEQR_TMPDIR" ]; then | |
#mkfifo $DECODEQR_TMPDIR/tmp.png | |
gnome-screenshot -f $DECODEQR_TMPDIR/tmp.png | |
zbarimg --quiet $DECODEQR_TMPDIR/tmp.png | |
rm -rf $DECODEQR_TMPDIR | |
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=ddclient service | |
After=network.target | |
[Service] | |
ExecStart=/usr/local/sbin/ddclient -file /etc/ddclient/ddclient.conf -daemon 300 -foreground -pid /dev/null | |
User=ddclient | |
Restart=always | |
RestartSec=300 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# LANGUAGE ScopedTypeVariables #-} | |
module LogFollower where | |
import Control.Concurrent (threadDelay) | |
import Control.Exception | |
import Data.ByteString.Char8 as BS | |
import Data.ByteString.Lazy as BL | |
import Data.IORef | |
import Data.Function(fix) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Distribution.Simple | |
import Distribution.Simple.Setup | |
import Distribution.Simple.LocalBuildInfo | |
import Distribution.PackageDescription | |
import Distribution.Version | |
import Text.Groom | |
-- This checks the direct dependency of the bytestring package being | |
-- compiled against to set the bytestring_has_itoa_c and |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// This is a demonstration of binary input into postgres using libpq. It | |
// is based on postgresql-9.0.2/src/test/examples/testlibpq3.c | |
// | |
// Create a table appropriate to this test in a database as follows: | |
// | |
// CREATE TABLE test (name BYTEA); | |
// | |
// See also http://article.gmane.org/gmane.comp.lang.haskell.cafe/85116 | |