##References
##Create Models
Create tables:
rails g model Location
rails g model User
rails g model Checkin
#!/usr/bin/ruby -w | |
require 'rubygems' | |
require 'hpricot' | |
require 'open-uri' | |
require 'spreadsheet' | |
class MetaReader | |
attr_reader :url, :outFile, :links, :book, :sheet1, :rownum | |
attr_accessor :url, :outFile, :links, :book, :sheet1, :rownum |
##References
##Create Models
Create tables:
rails g model Location
rails g model User
rails g model Checkin
- (NSString*)jsonStructureFromManagedObjects:(NSArray*)managedObjects; | |
- (NSArray*)managedObjectsFromJSONStructure:(NSString*)json withManagedObjectContext:(NSManagedObjectContext*)moc; | |
- (NSDictionary*)dataStructureFromManagedObject:(NSManagedObject*)managedObject | |
{ | |
NSDictionary *attributesByName = [[managedObject entity] attributesByName]; | |
NSDictionary *relationshipsByName = [[managedObject entity] relationshipsByName]; | |
NSMutableDictionary *valuesDictionary = [[managedObject dictionaryWithValuesForKeys:[attributesByName allKeys]] mutableCopy]; | |
[valuesDictionary setObject:[[managedObject entity] name] forKey:@"ManagedObjectName"]; | |
for (NSString *relationshipName in [relationshipsByName allKeys]) { |
{ | |
"USD": { | |
"symbol": "$", | |
"name": "US Dollar", | |
"symbol_native": "$", | |
"decimal_digits": 2, | |
"rounding": 0, | |
"code": "USD", | |
"name_plural": "US dollars" | |
}, |
import java.security.SecureRandom; | |
import javax.crypto.spec.PBEKeySpec; | |
import javax.crypto.SecretKeyFactory; | |
import java.math.BigInteger; | |
import java.security.NoSuchAlgorithmException; | |
import java.security.spec.InvalidKeySpecException; | |
/* | |
* PBKDF2 salted password hashing. | |
* Author: havoc AT defuse.ca |
<style> | |
/* ... */ | |
/*--- Preheader declaration in style block in addition to inline for Outlook */ | |
.preheader { display:none !important; visibility:hidden; opacity:0; color:transparent; height:0; width:0; } | |
</style> | |
</head> | |
<body> | |
<!-- PRE-HEADER TEXT --> | |
<span class="preheader" style="display: none !important; visibility: hidden; opacity: 0; color: transparent; height: 0; width: 0;">Preheader text shows up in GMail, iOS, Mail.app, & more: 75 text char limit</span> |
# Install linux update, followed by GCC and Make | |
sudo yum -y update | |
sudo yum install -y gcc make | |
# Install Nginx and PHP-FPM | |
sudo yum install -y nginx php-fpm | |
# Install PHP extensions | |
sudo yum install -y php-devel php-mysql php-pdo \ | |
php-pear php-mbstring php-cli php-odbc \ |
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE en-export SYSTEM "http://xml.evernote.com/pub/evernote-export3.dtd"> | |
<en-export export-date="20130730T205637Z" application="Evernote" version="Evernote Mac"> | |
<note> | |
<title>Test Note for Export</title> | |
<content> | |
<![CDATA[<?xml version="1.0" encoding="UTF-8" standalone="no"?> | |
<!DOCTYPE en-note SYSTEM "http://xml.evernote.com/pub/enml2.dtd"> | |
<en-note style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"> | |
Hello, World. |
'use strict'; | |
module.exports = function(grunt) { | |
// load all grunt tasks | |
require('matchdep').filterDev('grunt-*').forEach(grunt.loadNpmTasks); | |
// configurable paths | |
var paths = { |
#!/usr/bin/env ruby | |
#-*- encoding: utf-8 -*- | |
# http://blog.evernote.com/tech/2013/08/08/evernote-export-format-enex/ | |
require 'nokogiri' | |
require 'date' | |
require 'ostruct' | |
class Note < OpenStruct; end |