Skip to content

Instantly share code, notes, and snippets.

View djmitche's full-sized avatar

Dustin J. Mitchell djmitche

View GitHub Profile
@djmitche
djmitche / git-prompt.sh
Created January 15, 2009 16:59 — forked from henrik/.bashrc
edit existing PS1; be more efficient
# http://henrik.nyh.se/2008/12/git-dirty-prompt
# http://www.simplisticcomplexity.com/2008/03/13/show-your-git-branch-name-in-your-prompt/
# username@Machine ~/dev/dir [master] $ # clean working directory
# username@Machine ~/dev/dir [master*] $ # dirty working directory
# djmitche: *edit* an existing PS1 to add the git information
# djmitche: only invoke 'git' and 'sed' once (each) for each prompt
# djmitche: display [NO BRANCH] when not on a branch (e.g., during rebase -i)
# djmitche: almost completely replace with __git_ps1 from git contrib, which
# gives more information and avoids calling git scripts if possible
export LD_OPTIONS=-R/opt/cfengine/lib/
./Configure solaris-x86-gcc --prefix=/opt/cfengine/ no-dso
make
make install
[core]
repositoryformatversion = 0
filemode = true
bare = false
logallrefupdates = true
[user]
name = Chris AtLee
email = [email protected]
[remote "origin"]
url = git://github.com/djmitche/buildbot/
dustin@euclid ~/devel/projects/uthreads/t/virtual $ virtualenv .
New python executable in ./bin/python
Installing setuptools............done.
dustin@euclid ~/devel/projects/uthreads/t/virtual $ source bin/activate
(virtual)dustin@euclid ~/devel/projects/uthreads/t/virtual $ cd src
(virtual)dustin@euclid ~/devel/projects/uthreads/t/virtual/src $ python setup.py develop
running develop
running egg_info
writing requirements to uthreads.egg-info/requires.txt
writing uthreads.egg-info/PKG-INFO
<para>
Amanda automatically creates a bucket when writing, if the bucket doesn't
already exist. At that time, it specifies where Amazon should store the data
based on the S3_BUCKET_LOCATION property. Currently, there are two valid settings:
"*" (any location, probably US) and "EU" (Europe). If this property is not set,
Amazon's default value of "*" is used. The bucket location has both billing and legal concerns, so you are encouraged to consult Amazon's documentation for details.
</para>
<para>
Amazon does not permit changes to bucket locations, so this is a permanent
ok 7 - empty read from zero-length buffer
Breakpoint 2, zcloud_memory_upload_producer (buffer=0x804e070,
buffer_length=43) at memory_upload_producer.c:121
121 return ret;
(gdb) p *ret
$2 = {parent = {parent = {g_type_instance = {g_class = 0x8056458},
ref_count = 1, qdata = 0x0}},
buffer = 0x804e070 "The quick brown fox jumps over the lazy dog",
buffer_length = 43, buffer_position = 0}
my $obj1 = MyClass->new();
my $obj2 = MyClass->new();
my $someobj = $obj1;
not_ok($obj1 eq $obj2);
ok($obj1 eq $someobj);
# equality means identity here: if $oneobj eq $anotherobj,
# then after $oneobj->set_foo(10), $anotherobj->get_foo() returns 10
%inline %{
static gboolean same_elements(
XferElement *a,
XferElement *b)
{
return a == b;
}
%}
# ...
%perlcode {
/*
Originally By David Cuartielles
http://arduino.cc/en/Tutorial/Blink
based on an orginal by H. Barragan for the Wiring i/o board
*/
#define highpin 12
#define lowpin 7
// The setup() method runs once, when the sketch starts
#!/usr/bin/perl -w
use Device::SerialPort;
Device::SerialPort->new("/dev/ttyUSB0")->pulse_dtr_on(100);