This file contains hidden or 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 xml.etree import ElementTree | |
# For example create doc using ElmentTree | |
# ElementTree.fromstring(xml) | |
def rss_to__dict(doc): | |
# Create a Dictionary to store the data | |
# from the rss feed (xml) | |
rss = {"rss":[]} |
This file contains hidden or 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset=utf-8 /> | |
<title>jQuery Template</title> | |
</head> | |
<body> | |
<p></p> | |
<!-- |
This file contains hidden or 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/env python | |
# | |
# example of a byobu custom notification script | |
# place the file in $HOME/.byobu/bin | |
# make sure the script is executable (chmod +x) | |
# displays the kernel version | |
# every 10 seconds (NN_name where NN is the number of seconds) | |
import os | |
import sys |
This file contains hidden or 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/env bash | |
# h,f represent repeating content that could be | |
# required in multiple files. | |
h="1,15p" | |
f="122,125p" | |
sed -n "$h;44,56p;$f" index.html > last_hour_m1-page.html |
This file contains hidden or 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
if &term == "xterm-ipad" | |
imap jj <Esc> | |
endif |
This file contains hidden or 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
var express = require('express'), | |
stylus = require('stylus'), | |
routes = require('./routes'); | |
var app = module.exports = express.createServer(); | |
// Configuration | |
app.configure(function(){ |
This file contains hidden or 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
// npm install mongodb | |
var mongodb = require('mongodb'); | |
var url = require('url'); | |
var log = console.log; | |
var connectionUri = url.parse(process.env.MONGOHQ_URL); | |
var dbName = connectionUri.pathname.replace(/^\//, ''); | |
mongodb.Db.connect(process.env.MONGOHQ_URL, function(error, client) { | |
if (error) throw error; |
This file contains hidden or 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
var query = "select {[Measures].[Sales Amount], " + | |
"[Measures].[Average Sales Amount]} ON COLUMNS, " + | |
"[Product].[All Products].Children ON ROWS" + | |
" From [Sales Summary]"; | |
var rowset = function(mdx){ | |
xmla = new Xmla(); | |
return xmla.execute({ | |
async: false, | |
url: "http://localhost/olap/msmdpump.dll", |
This file contains hidden or 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
git svn clone --prefix=svn/ --stdlayout \ | |
--authors-file=authors.txt \ | |
--no-minimize-url http://plugins.svn.wordpress.org/tweet/ |
This file contains hidden or 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/env python | |
import httplib2 | |
from urllib import urlencode | |
import json | |
url_login = "https://www.lordofultima.com/en/user/login" | |
url_main = "http://prodgame05.lordofultima.com/197/" | |
url_game = "%sindex.asp" % (url_main) | |
url_ajax = "%sPresentation/Service.svc/ajaxEndpoint/" % (url_main) |
OlderNewer