RubyMotion projects can be extended through the use of RubyGems, the Ruby de-facto packaging system. This article will cover how to write RubyMotion-specific gems.
This article was inspired by Create gems for RubyMotion, by Francis Chong.
RubyMotion projects can be extended through the use of RubyGems, the Ruby de-facto packaging system. This article will cover how to write RubyMotion-specific gems.
This article was inspired by Create gems for RubyMotion, by Francis Chong.
<?xml version="1.0" encoding="UTF-8"?> | |
<kml xmlns="http://www.opengis.net/kml/2.2"> | |
<Document> | |
<name>Appsterdam Heatmap</name> | |
<open>1</open> | |
<description>The Appsterdam Tech Scene</description> | |
<Style id="mainIcon"> | |
<IconStyle> | |
<Icon> | |
<href>http://maps.google.com/mapfiles/kml/pal4/icon28.png</href> |
# | |
# Calculate your number according to http://www.astrology.com/what-numerology/2-d-d-66854 | |
# | |
# | |
# HOW ARE NUMEROLOGY CALCULATIONS DONE | |
# In numerology, all numbers are reduced to the single digits 1 through 9 except the special master numbers 11 and 22. 1, 2, 3, 4, 5, 6, 7, 8, 9, 11 and 22 represent the major vibration rates associated with people’s characteristics. | |
# The numbers are reduced by simple addition. The number 15, for instance, is reduced by adding 1 + 5 to get 6. Similarly, the number 1974 can be reduced by adding 1 + 9 + 7 + 4 to get 21. The 21 can be further reduced by adding 2 + 1 to get 3. | |
# Letters in individuals’ names are converted to numbers and then added together. These numbers, in turn, are also reduced. The letter A, for instance, is 1; the letter B is 2; the letter C is 3, and so forth. The following table shows the numbers assigned to all 26 letters in the English alphabet. | |
# | |
# 1 2 3 4 5 6 7 8 9 |
#import <SenTestingKit/SenTestingKit.h> | |
#import <CoreData/CoreData.h> | |
@interface MyCoreDataTests : SenTestCase | |
{ | |
NSManagedObjectModel *managedObjectModel; | |
NSPersistentStoreCoordinator *persistentStoreCoordinator; | |
NSManagedObjectContext *managedObjectContext; | |
} | |
- (void)setupCoreDataEnvironment; |
#import <SenTestingKit/SenTestingKit.h> | |
#import <CoreData/CoreData.h> | |
@interface MyCoreDataTests : SenTestCase | |
{ | |
NSManagedObjectModel *managedObjectModel; | |
NSPersistentStoreCoordinator *persistentStoreCoordinator; | |
NSManagedObjectContext *managedObjectContext; | |
} | |
@end |
module Bacon | |
def self.context_did_finish(context) | |
handle_specification_end | |
Counter[:context_depth] -= 1 | |
if (@current_context_index + 1) < @contexts.size | |
@current_context_index += 1 | |
run | |
else | |
# DONE | |
handle_summary |
class Bacon::Context | |
def runloop(duration=0.6) | |
Thread.new { | |
runloop = NSRunLoop.currentRunLoop | |
yield | |
runloop.runUntilDate(NSDate.dateWithTimeIntervalSinceNow(duration)) | |
}.join | |
end | |
end |
require "rmagick" | |
require "fileutils" | |
[ | |
{ :path => 'medium', :max_width => 125, :max_height => 450}, | |
{ :path => 'normal', :max_width => 200, :max_height => 200}, | |
{ :path => 'micro', :max_width => 65, :max_height => 65} | |
].each do |opts| | |
max_height = opts[:max_height] | |
max_width = opts[:max_width] |
# | |
# MacRuby distributed objects poc. | |
# | |
# Inspired by the Distributed Object chapter in "Advanced Mac Os X Programming" by Dalrymple and Hillegass | |
# | |
# Klaas Speller | |
# http://www.github.com/spllr | |
# | |
# Use at own risk (that's what the lisence is for). | |
# Its still buggy and I would love some input on good usage of the NSRunLoop with MacRuby |
# macport | |
if [ -d /opt/local/etc/macports ]; then | |
PATH=/opt/local/etc/macports:"${PATH}" | |
fi | |
if [ -d /opt/local/bin/ ]; then | |
PATH=/opt/local/bin/:"${PATH}" | |
fi | |
if [ -d ~/bin/ ]; then |