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
<gap:config-file overwrite="true" parent="NSLocationWhenInUseUsageDescription" platform="ios"> | |
<string>Your custom text here</string> | |
</gap:config-file> |
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
# Calcul du chiffre-clé, modulo 10, récursif BVR Suisse | |
# Berechnung der Prüfziffer nach Modulo 10, rekursiv BESR Schweiz | |
# Calculating the Check Digits Using Module 10, Recursively | |
def modulo10_checksum(number) # Best to send a string, an integer with leading 0's will be interpreted as octal... | |
# table from https://www.credit-suisse.com/media/production/pb/docs/unternehmen/kmugrossunternehmen/besr_technische_dokumentation_fr.pdf | |
table = [ | |
[0,9,4,6,8,2,7,1,3,5], | |
[9,4,6,8,2,7,1,3,5,0], |
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
# Encoding: utf-8 | |
# IN GEMFILE : gem 'wombat' #does the scraping magic | |
class WeatherData < ActiveRecord::Base | |
require 'open-uri' | |
require 'digest/md5' | |
attr_accessible :max_wind, :mean_wind, :sea_level_pressure, :station_code, :station_id, :temp, :time_stamp, :wind_direction, :conditions | |
belongs_to :station | |
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
function doYLine(screenX, xMax, yMax) | |
{ | |
computedLine = new String ; | |
computedLine = screenX ; | |
xZoom = xMax/1000.0/.5 ; | |
yZoom = yMax/1000.0/.5 ; | |
xThingy = screenX/xMax ; | |
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
xMax = window.innerWidth ; | |
yMax = window.innerHeight ; | |
maxThreads = 6 ; | |
function workerMessage(thread) { | |
return '' +thread + ' ' + xMax + " " + yMax ; | |
} | |
var b_canvas = document.getElementById("a"); |
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
svn remove log/* | |
svn commit -m 'removing all log files from subversion' | |
svn propset svn:ignore "*.log" log/ | |
svn update log/ | |
svn commit -m 'Ignoring all files in /log/ ending in .log' | |
svn remove tmp/* | |
svn commit -m 'removing all tmp artifacts from subversion' | |
svn propset svn:ignore "*" tmp/ | |
svn update tmp/ |
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
int ledPin = 0 ; | |
int catPin = 8 ; | |
int buttonUp = 14 ; | |
int buttonDown = 15 ; | |
int number = 0 ; | |
unsigned long time, oldTime ; | |
int numbers[10][8]={{HIGH,HIGH,HIGH,HIGH,HIGH,HIGH,LOW,LOW}, |
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 'rubygems' | |
require 'logger' | |
gem 'builder' | |
require 'net/http' | |
gem 'Floppy-eeml' | |
require 'eeml' | |
logger = Logger.new("#{File.dirname(__FILE__)}/pachube.log") | |
PACHUBE_KEY = #YOUR KEY HERE | |
digits = /\d+/ |