Download - NuGet for The Enterprise
![Page 1: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/1.jpg)
NuGet for The Enterprise.NET Package Management
Scott HanselmanPrincipal Program ManagerMicrosoft
DEV338
![Page 2: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/2.jpg)
2
![Page 3: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/3.jpg)
CastleN
Hib
ern
ate
log4net
NUnit
Elm
ah
Nin
ject
Antlr
Iesi Collections
jQuery
New
tonso
ft.Jso
n
Moq
FluentNHibernate
AutoMapperStructureMap
NLog
Autofac
Facebook SDKRx
RhinoMocks
MvcContrib
51Degrees.mobiD
otN
etO
pen
Au
th
Com
mon
.Log
gin
g
MvvmLight
BBCode
Mvc
Mai
ler
xuni
t
Flu
entV
alid
atio
n
Ham
moc
k
SharpZipLib
FluentHtml-ciMachine.Specifications
jQuery.Validation
WatiN
Htm
lAgi
lityP
ack
Simple.Data.Core
CLEditor
Simple.Data.CoreAltairis.Web.Security
UrlShortener.HelperiT
extS
harp
QuickGraph
DotNetZip
FakeItEasy
PublishSettingsGenerator
Spa
rk
NSubstitute
RavenDB
Luce
ne
AutoPoco
RestSharp
Should
postalnservicebus
reac
tive
ui-c
ore
linq
.js
fast
erfle
ct
combres
TweetSharp
MvcSiteMapProvider
Ad
am.J
SG
en
era
tor
Flu
en
tAss
ert
ion
s
Bootstrapper
AzureToolkit
ErikEJ.SqlCeMembership
![Page 4: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/4.jpg)
What’s my goal here?
![Page 5: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/5.jpg)
![Page 6: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/6.jpg)
Make using OSS as easy as “Add Reference”
![Page 7: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/7.jpg)
Make using software as easy as “Add Reference”
![Page 8: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/8.jpg)
How do we do that?
![Page 9: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/9.jpg)
BUILD UP THE DEVELOPERECOSYSTEM
![Page 10: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/10.jpg)
Adding a library to a project
What is the experience to add an existing 3rd Party or open source library to a project today?Let’s take a look
![Page 11: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/11.jpg)
Like all good stories, it
starts with a Google search
![Page 12: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/12.jpg)
Like all good stories, it
starts with a Bing
search
![Page 13: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/13.jpg)
So far so good in this case.
![Page 14: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/14.jpg)
This looks right
![Page 15: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/15.jpg)
![Page 16: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/16.jpg)
?Turns out, this is the right one.
![Page 17: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/17.jpg)
Looks right to me,
I guess.
![Page 18: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/18.jpg)
![Page 19: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/19.jpg)
![Page 20: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/20.jpg)
Before we extract it, we need to visit
the Properties
![Page 21: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/21.jpg)
Don’t forget this!
![Page 22: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/22.jpg)
![Page 23: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/23.jpg)
![Page 24: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/24.jpg)
Extract assemblies to a folder within
the solution directory
![Page 25: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/25.jpg)
![Page 26: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/26.jpg)
![Page 27: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/27.jpg)
![Page 28: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/28.jpg)
Need to add the correct
configuration to web.config
![Page 29: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/29.jpg)
![Page 30: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/30.jpg)
Finally! It works!
![Page 31: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/31.jpg)
that‘s for a single assembly!
![Page 32: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/32.jpg)
What Happens When I’m Ready For Build V2?
![Page 33: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/33.jpg)
we can do much better!
![Page 34: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/34.jpg)
Our NuGet Agenda
Basics: What it can doMaking Packages & PublishingCommand-line vs. UIExamples from Simple to Advanced
Conventions, Transforms and Preprocessing, PowerShell
NuGet Servers of all SizesNuGet and Source ControlNuGet and Continuous Integration Extreme Examples
![Page 35: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/35.jpg)
What about the Enterprise?
![Page 36: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/36.jpg)
http://flic.kr/photos/kwl/3875936992/
![Page 37: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/37.jpg)
What about big boring companies?
![Page 38: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/38.jpg)
What problem are we trying to solve?
Sharing business level components among teams.Sharing best practices among teams.Build productivity helpers on top of existing Out of the Box, Open Source or 3rd party tools and libraries.Setup configuration that is specific to the enterprise environment.
![Page 39: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/39.jpg)
How is this solved today
File shares with folders full of assemblies or downloaded 3rd party installers.Tribal knowledgeSparse documentation in wikis or email threads.Pulled from existing source code trees within the company.
![Page 40: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/40.jpg)
How does NuGet help?
Provides a central location to store this knowledge, in the form of code, assemblies, configuration, and automation scripts.Provides concrete solutions rather than guidance, policies, or abstract standards.
![Page 41: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/41.jpg)
Using NuGet in the enterprise.
Setup a Company Repository.For a single location use a UNC shareDistributed companies should use a http server.
Start by manually packaging up existing company shared libraries and components and their configuration.Create meta packages to share better practices.
![Page 42: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/42.jpg)
Create a Meta package
Meta package is a package that does not contain assemblies or code. It only combines a set of dependent packages.
ExamplesTesting package could have your unit test, assertion, and mocking frameworkApplication – IoC, ORM, ect… The reference app that can install into a MVC 3 Empty template.
![Page 43: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/43.jpg)
Continuous Integration
Create a second Repository for CI builds.Automate the NuGet Package creation from your CI builds to publish to the CI RepositoryAutomatically increment your version numbers in your assemblies and NuGets
![Page 44: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/44.jpg)
Define a Publishing process
Define a process for when your Nuggets are published to the official company repository.After a development iteration all your release/acceptance tests pass.Publish your package to the Released feed.
![Page 45: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/45.jpg)
Automation scripts
Automate solution to common errors.ConfigurationsInstall assemblies in the GACCreate Event Log SourcesEct.
Use the Package Manager Console to interactivly create a solution to a reproducible support problems.
![Page 46: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/46.jpg)
Hacking NuGet “things the product team will tell you not to do”
Distribute additional Visual Studio Add-ins (VSIX).Distribute code templates.Add additional commands to the package console to carry out common developer tasks.Change base classes for files in your VS project. Add method overrides….. Ect. This can all be done in powershell.
![Page 47: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/47.jpg)
Changing a global.asax base class demo
![Page 48: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/48.jpg)
PILE OF DEMOS!NuGet
![Page 49: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/49.jpg)
Development
NuGet is an OuterCurve Foundation ProjectHosted on http://nuget.codeplex.comExternal contributions allowed
Several external core contributorsMonthly point release cadenceLarge uptake so far: http://stats.nuget.org
![Page 50: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/50.jpg)
help us spread the word!
![Page 52: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/52.jpg)
Web Track Resources
http://www.asp.net/http://www.silverlight.net/http://www.microsoft.com/web/gallery/http://www.iis.net/http://weblogs.asp.net/Scottgu/http://www.hanselman.com
![Page 53: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/53.jpg)
Resources
www.microsoft.com/teched
Sessions On-Demand & Community Microsoft Certification & Training Resources
Resources for IT Professionals Resources for Developers
www.microsoft.com/learning
http://microsoft.com/technet http://microsoft.com/msdn
Learning
http://northamerica.msteched.com
Connect. Share. Discuss.
![Page 54: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/54.jpg)
Complete an evaluation on CommNet and enter to win!
![Page 55: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/55.jpg)
Scan the Tag to evaluate this session now on myTech•Ed Mobile
![Page 56: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/56.jpg)
© 2011 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries.The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to
be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS
PRESENTATION.
![Page 57: NuGet for The Enterprise](https://reader031.vdocuments.mx/reader031/viewer/2022012922/556415a4d8b42a080c8b55bc/html5/thumbnails/57.jpg)