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
class HomeController < ApplicationController | |
def index | |
doc = Nokogiri::HTML(open('http://www.tenoaksnursery.com')) | |
@option = doc.css('option') | |
render :index | |
end | |
end |
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
cl_crosshair_drawoutline 1 | |
cl_crosshair_outlinethickness 1 | |
cl_crosshaircolor 5 | |
cl_crosshaircolor_b 255 | |
cl_crosshaircolor_r 255 | |
cl_crosshaircolor_g 255 | |
cl_crosshairalpha 255 | |
cl_crosshairthickness 2.6 | |
cl_crosshairsize 0.5 | |
cl_crosshairgap -1 |
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
--- | |
:bulk_threshold: 1000 | |
gem: --no-ri --no-rdoc | |
:verbose: true | |
gemcutter_key: | |
:benchmark: false | |
:update_sources: true | |
:backtrace: false | |
:sources: | |
- http://gemcutter.org |
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
(ns server.core | |
(:require [compojure.core :refer :all] | |
[compojure.handler :refer [site]] | |
[ring.util.response :refer [response status]] | |
[ring.adapter.jetty :refer [run-jetty]] | |
[cheshire.core :as json])) | |
(def players (atom ())) | |
(defn list-players [] |
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 java.util.concurrent.locks.ReentrantLock; | |
public class Interruptible { | |
public static void main(String[] args) throws InterruptedException { | |
final ReentrantLock l1 = new ReentrantLock(); | |
final ReentrantLock l2 = new ReentrantLock(); | |
Thread t1 = new Thread() { | |
public void run() { |
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
public class Uninterruptible { | |
public static void main(String[] args) throws InterruptedException { | |
final Object o1 = new Object(); final Object o2 = new Object(); | |
Thread t1 = new Thread() { | |
public void run() { | |
try { | |
synchronized(o1) { | |
Thread.sleep(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
public class Counting { | |
public static void main(String[] args) throws InterruptedException { | |
class Counter { | |
private int count = 0; | |
public synchronized void increment() { ++count; } | |
public int getCount() { return count; } | |
} | |
final Counter counter = new Counter(); | |
class CountingThread extends Thread { | |
public void run() { |
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
#include <stdio.h> | |
#include <stdlib.h> | |
int main() | |
{ | |
char card_name[3]; | |
int count = 0; | |
while (card_name[0] != 'X') { | |
puts("Enter the card 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
"images": [ | |
{ | |
"url": "http://dummyimage.com/600x400/000/fff.jpg&text=Spree T-Shirt" | |
}, | |
{ | |
"url": "http://dummyimage.com/600x400/000/fff.jpg&text=Spree T-Shirt2" | |
} | |
], |
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/env ruby | |
$stdout.sync = true | |
require File.join(File.expand_path('../..', __FILE__), %w[lib falkor]) | |
puts 'You should not run this command with any worker running. Are all workers stopped [y/n]?' | |
exit 0 unless 'y' == gets.chomp.downcase | |
puts 'Update all legacy transforms [y/n]?' |