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
#!/usr/bin/ruby | |
# Download NASA MODIS imagery and use it as a desktop background. | |
# You'll need ImageMagick installed for this to work. | |
require 'date' | |
require 'net/http' | |
# Screen width/height | |
X = 2580 | |
Y = 1024 |
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
<html> | |
<head> | |
<title>A Little Bit of PHP</title> | |
<style type="text/css"> | |
td {font-size: 8pt; font-family: Arial;} | |
</style> | |
</head> | |
<?php |
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
#!/usr/bin/perl | |
use Net::Amazon; | |
use Net::Amazon::Request::Wishlist; | |
use Net::Amazon::Request::ASIN; | |
use DBI; | |
use Product; | |
use Price; | |
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
#!/usr/bin/perl | |
use Net::Amazon; | |
use Net::Amazon::Request::Wishlist; | |
use DBI; | |
use Product; | |
sub createRecord{ | |
my $rec = shift; |
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
<?php | |
<html> | |
<head> | |
<title>Sybase Test</title> | |
</head> | |
<body> | |
Testing execution<br /> | |
<?= print_sybase_version() ?> |
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
#!/usr/bin/ruby | |
require 'dbi' | |
require 'odbc' | |
dbh = DBI.connect('DBI:ODBC:prod', 'username', 'password') | |
query = "select getdate()" | |
row = dbh.select_one(query) | |
puts "got a value of: " + row[0].to_s |
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
[TDS] | |
Description = TDS driver (Sybase/MS SQL) | |
Driver = /usr/lib/libtdsodbc.so | |
Setup = /usr/lib/libtdsS.so | |
FileUsage = 1 | |
CPTimeout = | |
CPReuse = |
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
[prod] | |
Driver = /usr/lib/libtdsodbc.so | |
Description = ODBC | |
Trace = No | |
Servername = PROD | |
Database = <database_name> |
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
[PROD] | |
host = sybase_hostname | |
port = sybase_port | |
tds version = 5.0 |
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 | |
# | |
# Determine if master and slave mysql servers are in sync | |
# If not, report it via STDOUT and non-zero return code | |
# If are in sync, exit successfully | |
# | |
# Paramters: | |
# -v - verbose, show stats even if 100% synchronized | |
USER='YOUR_USER_NAME' |
OlderNewer