Does your osx terminal speak java 7? Start Terminal.app and try: java -version:
> java -version
java version "1.7.0_51"
Java(TM) SE Runtime Environment (build 1.7.0_51-b13)
Java HotSpot(TM) 64-Bit Server VM (build 24.51-b03, mixed mode)| #I @"packages\FSharp.Data.Toolbox.Twitter.0.6\lib\net40" | |
| #I @"packages\FSharp.Data.2.1.1\lib\net40" | |
| #r @".\packages\FSharp.Data.Toolbox.Twitter.0.6\lib\net40\FSharp.Data.Toolbox.Twitter.dll" | |
| #r @".\packages\FSharp.Data.2.1.1\lib\net40\FSharp.Data.dll" | |
| open FSharp.Data.Toolbox.Twitter | |
| // Check out https://apps.twitter.com for more info on getting key & secret! | |
| let key = "" //Insert key here! |
| (* | |
| This script analyzes the dependencies between top level types in a .NET Assembly. | |
| It is then used to compare the dependency relationships in some F# projects with those in some C# projects. | |
| Note that no attempt has been made to optimize the code yet! | |
| REQUIRES: | |
| * Mono.Cecil for code analysis | |
| From http://www.mono-project.com/Cecil#Download |
| namespace Topshelf | |
| [<AutoOpen>] | |
| module Topshelf = | |
| open System | |
| open Topshelf.HostConfigurators | |
| open Topshelf.Runtime | |
| let configureTopShelf f = |
| type BusyBuilder(blockUi, unblockUi) = | |
| member this.Bind(x, f) = async.Bind(x, f) | |
| member this.Combine(e1, e2) = async.Combine(e1, e2) | |
| member this.Delay(f) = | |
| async { | |
| blockUi () | |
| let! result = async.Delay f | |
| unblockUi () | |
| return result | |
| } |
| #r "../packages/FSharp.Data.2.2.5/lib/net40/FSharp.Data.dll" | |
| open System | |
| open System.IO | |
| open FSharp.Data | |
| [<Literal>] | |
| let lineBreak = "\r\n" | |
| type CommitInfo = {Hash : string; Author : string; TimeStamp : DateTime; Message : string} | |
| type CommittedFile = {LinesAdded: int option; LinesDeleted: int option; FileName: string} |
L1 cache reference ......................... 0.5 ns
Branch mispredict ............................ 5 ns
L2 cache reference ........................... 7 ns
Mutex lock/unlock ........................... 25 ns
Main memory reference ...................... 100 ns
Compress 1K bytes with Zippy ............. 3,000 ns = 3 µs
Send 2K bytes over 1 Gbps network ....... 20,000 ns = 20 µs
SSD random read ........................ 150,000 ns = 150 µs
Read 1 MB sequentially from memory ..... 250,000 ns = 250 µs
| open System.Collections.Generic | |
| open Microsoft.FSharp.Collections | |
| [<RequireQualifiedAccess>] | |
| module Folds = | |
| // These are the fast implementations we actually want to use |
| #r "packages/Twilio/lib/net451/Twilio.dll" | |
| #r "System.Xml.Linq" | |
| open System | |
| open Twilio.TwiML | |
| open Twilio.TwiML.Voice | |
| module Model = | |
| /// Represents what we will tell the Twilio phone system to do | |
| type PhoneCommand = |