Skip to content

Instantly share code, notes, and snippets.

View jmetzmeier's full-sized avatar

Jordan Metzmeier jmetzmeier

View GitHub Profile
$ cat /tmp/test.sh
#!/bin/bash
foo="a x,y,z"
read -r x csv <<< "$foo"
IFS=, read -ra y <<< "$csv"
printf "$x %s\n" "${y[@]}"
$ bash /tmp/test.sh
a x
a y
class foo::bar (
$server = $foo::params::server,
$bar = $foo::params::bar,
) inherits foo::params {}
class foo::params (
$server = 'someserver',
) {
$bar = "${server}_string"
}
(testvenv2)jordan@tesla ~/prog/vagrant (master) $ bundle install
Resolving dependencies...
Using rake 10.4.2
Using addressable 2.3.8
Using builder 3.2.2
Using bundler 1.7.4
Using ffi 1.9.8
Using childprocess 0.5.5
Using safe_yaml 1.0.4
Using crack 0.4.2
--- rules (revision 26689)
+++ rules (revision 26687)
@@ -11,9 +11,8 @@
dh $@ --with python2 --buildsystem=pybuild
override_dh_auto_test:
- PYBUILD_SYSTEM=custom \
- PYBUILD_TEST_ARGS="cd {build_dir}; django-admin test $(MY_DJANGOADMIN_OPTION) --settings=django_conneg.test_settings --pythonpath=. django_conneg.tests" \
- dh_auto_test
+ pybuild $(MY_PYBUILD_OPTION) --test -i python{version} -p 2.7 --dir . --system=custom --test-args 'cd {build_dir}; django-admin test $(MY_DJANGOADMIN_OPTION) --settings=django_conneg.test_settings --pythonpath=. django_conneg.tests'
@jmetzmeier
jmetzmeier / gist:f20d6dcebf2a65e4bcc1
Created September 29, 2014 04:57
Why do these not equal?
type clock struct {
h int
m int
}
func New(hours int, minutes int) *clock {
c := new(clock)
c.h = hours
c.m = minutes
return c
SOAPpy/Client.py:
from Config import Config
...
class SOAPAddress:
def __init__(self, url, config = Config):
if proto == 'httpg' and not config.GSIclient:
...
------------------------