This file contains hidden or 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
#r "Nuget.Core" | |
#r "System.Xml.Linq" | |
open NuGet | |
open System | |
open System.Linq | |
let repoFac = new PackageRepositoryFactory() | |
let repo = repoFac.CreateRepository("http://btn-tc01:8083") | |
let FiveFiveVersion = new SemanticVersion("5.5.0") | |
let packages = repo.FindPackages("Database.PASNGR", new VersionSpec(), false, false) |
This file contains hidden or 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
module PktHdrStorableInstance where | |
import Foreign.Marshal.Utils (with) | |
import Foreign.Ptr (plusPtr) | |
import Foreign.Storable | |
import Network.Pcap | |
import Network.Pcap.Base (toPktHdr) | |
#include <pcap.h> |
This file contains hidden or 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
{-# LANGUAGE DeriveDataTypeable #-} | |
import Control.Concurrent (threadDelay) | |
import Control.Exception (Exception,throw) | |
import Control.Monad (void) | |
import Control.Concurrent.Async (Async,race,wait,withAsync) | |
import Data.Typeable (Typeable) | |
data ThreadTimeoutException = ThreadTimeoutException | |
deriving (Show, Typeable) |
This file contains hidden or 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
package com.micronautics.paypal | |
import java.util.{ List, Map } | |
import collection.JavaConversions._ | |
import collection.immutable.HashMap | |
import controllers.Email | |
import org.joda.time.DateTime | |
import slick.driver.MySQLDriver.simple._ | |
import java.util |
This file contains hidden or 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
/// | |
/// Example building a package (from the NuGet PackageBuilderTest.cs class) | |
/// | |
// Act | |
var builder = new PackageBuilder { Id = "test", Version = new SemanticVersion("1.0"), Description = "test" }; | |
builder.Authors.Add("test"); | |
foreach (var name in fileNames) | |
{ |
This file contains hidden or 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
private static string GetAssemblyDirectory() | |
{ | |
return new System.IO.FileInfo(System.Reflection.Assembly.GetExecutingAssembly().Location).Directory.FullName; | |
} |
This file contains hidden or 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
// And by the way, please feel free to contribute, correct errors, etc! | |
trait Functor[F[_]] { | |
def fmap[A, B](f: A => B): F[A] => F[B] | |
} | |
object Functor { | |
val ListFunctor: Functor[List] = | |
new Functor[List] { | |
def fmap[A, B](f: A => B) = |
This file contains hidden or 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
def detectDriverNameFromUrl(url : String) : Option[String] = { | |
val splits = url.split(":") | |
if(splits.length < 2){ | |
return None | |
} | |
if(splits(0) != "jdbc"){ | |
return None | |
} |
This file contains hidden or 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
(** | |
## References | |
As they aren't part of a project, fsx files need | |
to reference all of their dependencies within the | |
file. | |
You'll always want to reference FakeLib. VersionUpdater | |
is an inhouse tool we use for handling feature branch |
This file contains hidden or 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
(** | |
## References | |
As they aren't part of a project, fsx files need | |
to reference all of their dependencies within the | |
file. | |
You'll always want to reference FakeLib. VersionUpdater | |
is an inhouse tool we use for handling feature branch |