Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/env python
## Boot a Managed Jenkins Slave
#
#
#
#
import os
from argparse import ArgumentParser
from subprocess import call
import sys
#!/usr/bin/env perl
# Test whether a scalar in perl is numeric or not.
#
# ( ( $i + 0 ) ne $i ) ? "not numeric" : "numeric";
#
# - ` $i + 0 ` converts scalar to numeric
# - which should then not equal $i unless it is a numeric
#
use strict;
use String::Random qw(random_regex random_string);
use ModelSEED::ObjectManager;
use Devel::Size qw(total_size);
use Time::HiRes qw(time);
use Data::Dumper;
use Test::More tests => 1;
my $om = ModelSEED::ObjectManager->new({
database => $ENV{HOME}."/test.db",
driver => "SQLite",
});
@devoid
devoid / mysql2sqlite.sh
Created August 27, 2011 00:00 — forked from esperlu/mysql2sqlite.sh
MySQL to Sqlite converter
#!/bin/sh
# Converts a mysqldump file into a Sqlite 3 compatible file. It also extracts the MySQL `KEY xxxxx` from the
# CREATE block and create them in separate commands _after_ all the INSERTs.
# Awk is choosen because it's fast and portable. You can use gawk, original awk or even the lightning fast mawk.
# The mysqldump file is traversed only once.
# Usage: $ ./mysql2sqlite mysqldump-opts db-name | sqlite3 database.sqlite
# Example: $ ./mysql2sqlite --no-data -u root -pMySecretPassWord myDbase | sqlite3 database.sqlite