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 | |
require 'fileutils' | |
require 'optparse' | |
SOURCEDIR='/Volumes/root/skripte' | |
DESTDIR="/Users/#{ENV['USER']}/Dropbox/Documents/HSR/Semester5/skripte" | |
Subject = Struct.new :source, :destination, :parameters | |
SUBJECTS = [ |
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 MockArticlesHard | |
@@articles = {} | |
def initialize | |
return unless @@articles.empty? | |
@@articles[:article_aab] = FactoryGirl.create(:article_aab) | |
@@articles[:article_bla] = FactoryGirl.create(:article_bla) | |
@@articles[:article_blub] = FactoryGirl.create(:article_blub) | |
@@articles[:article_blub_blub] = FactoryGirl.create(:article_blub_blub) |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.6.2/jquery.min.js" type="text/javascript"></script> | |
<script type="text/javascript"> | |
function f() { | |
console.log("bla"); | |
$.ajax({ | |
url : 'http://152.96.80.18:8080/api/trails', | |
type : 'get', |
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
require 'open-uri' | |
require 'nokogiri' | |
url = 'http://www.admin.ch/ch/d/sr/101/index.html' | |
doc = Nokogiri::HTML(open(url)) | |
toc = doc.css('#spalteContentPlus') | |
NewerOlder