NuGet bootstrap script

Robin Neatherway - Fri 26 September 2014 - fsharp, nuget

When working with F# scripts I often want to install and use a NuGet package. As NuGet isn't installed with Mono, and I work on a few different machines I wanted a simple solution to make sure it was available. I have my dot files managed in a git repository, so I added the following short bash script to my .bin directory (which is on my $PATH). This downloads NuGet if it isn't already present, and executes launches it with mono. I also added ~/.bin/NuGet.exe to my .gitignore.



if [[ ! -e ${NUGET} ]]; then
    wget -O ${NUGET}

mono ${NUGET} "$@"