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
try { | |
ConfigurationBuilder builder = new ConfigurationBuilder(); | |
builder.setOAuthAccessToken("configure") | |
.setOAuthAccessTokenSecret("these") | |
.setOAuthConsumerKey("params") | |
.setOAuthConsumerSecret("in twitter"); | |
//twitter4j | |
Twitter twitter = new TwitterFactory(builder.build()).getInstance(); | |
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
var http = require('http'); | |
var events = require('events'); | |
function show_status(user) { | |
var emitter = new events.EventEmitter; | |
emitter.on('received', function(evtdata){ | |
var tweet = eval(evtdata); |
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>Ajax File Poller plugin example</title> | |
<script language="javascript" src="utils/jquery-1.6.2.min.js"><!--ff and opera--></script> | |
<script type="text/javascript" src="utils/jquery.url.poller.js"><!-- ff and opera --></script> | |
<script type="text/javascript" src="utils/progress.js"><!-- ff and opera --></script> | |
<link href="utils/progress.css" type="text/css" rel="stylesheet"/> | |
<body> | |
<form> | |
File Output: <br/> |
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
$(document).ready(function() { | |
$.timerLoad.load({ | |
fadeOutTime: 1000 | |
} | |
); | |
}); |
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
/** | |
* Author: Suresh Khatri | |
* Plugin: Dynamic URL Poller | |
* Released under the MIT, BSD, and GPL Licenses. | |
**/ | |
(function($){ | |
var urlToPoll = "./"; | |
var interval; | |
$.timerLoad = function() { |
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/sh | |
# | |
# Usage: ./bulkrename.sh /backup/project dump data_backup_ | |
# | |
# the files matching the pattern | |
# YYYdumpXXXX will be converted to | |
# YYYdata_backup_XXXX | |
# | |
# |
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>Geo</title> | |
<script> | |
window.addEventListener('load', function() { | |
if (navigator.geolocation) { |
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
package com.mybuild | |
import org.gradle.api.DefaultTask | |
import org.gradle.api.tasks.TaskAction | |
class AddDependencyTask extends DefaultTask { | |
def libMap | |
@TaskAction | |
void addLibrariesInBulk() { |
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
DROP TABLE IF EXISTS version_info; | |
create table version_info( | |
version bigint(10) not null, | |
filename varchar(100), | |
starttime timestamp, | |
endtime timestamp, | |
primary key(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
import org.apache.commons.dbcp.BasicDataSource | |
apply plugin:'eclipse' | |
propFile="${rootProject.projectDir}/config/database.properties" | |
prod=false | |
buildscript { | |
buildDeps = ['commons-pool:commons-pool:1.5.4', 'commons-io:commons-io:2.0.1', 'commons-dbcp:commons-dbcp:1.3', | |
'mysql:mysql-connector-java:5.1.13'] |
OlderNewer