Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
package main | |
import ( | |
"fmt" | |
"net/http" | |
"time" | |
) | |
var urls = []string{ | |
"https://splice.com/", |
Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
package main | |
import ( | |
"os" | |
"fmt" | |
) | |
type Fetcher interface { | |
// Fetch returns the body of URL and | |
// a slice of URLs found on that page. |
# Runs a specified shell command in a separate thread. | |
# If it exceeds the given timeout in seconds, kills it. | |
# Returns any output produced by the command (stdout or stderr) as a String. | |
# Uses Kernel.select to wait up to the tick length (in seconds) between | |
# checks on the command's status | |
# | |
# If you've got a cleaner way of doing this, I'd be interested to see it. | |
# If you think you can do it with Ruby's Timeout module, think again. | |
def run_with_timeout(command, timeout, tick) | |
output = '' |
// Titanium Mobile code for slider control functionality | |
//---------------------------------------- | |
// @CJ_Reed 23rd Dec 2010 | |
var sliderView = Titanium.UI.createView({top:100,height:50,left: 40,width:240,backgroundColor:'#000'}); | |
var sliderButton = Titanium.UI.createView({width:96,borderRadius:5,backgroundColor:'#bbb',height:sliderView.height,left:sliderView.left,top:sliderView.top}); | |
Titanium.UI.currentWindow.add(sliderView); | |
Titanium.UI.currentWindow.add(sliderButton); | |
function unlock (){ |
=Navigating= | |
visit('/projects') | |
visit(post_comments_path(post)) | |
=Clicking links and buttons= | |
click_link('id-of-link') | |
click_link('Link Text') | |
click_button('Save') | |
click('Link Text') # Click either a link or a button | |
click('Button Value') |