This guide will show you
- how to manually setup Paket in your .NET / mono solutions
- and how to use the automatic NuGet conversion.
The following guide is assuming you are using the paket.exe command line tool. For information on installing the command line tool follow the instructions for your operating system for installation. There are editor plugins for Visual Studio, Atom and other which can make this process easier and provide additional tooling like syntax highlighting. Check our editor support page to see if your editor has a Paket plugin.
If you are starting a new solution from scratch then take a look at ProjectScaffold. This project helps you get started with a new .NET/Mono project solution with everything needed for successful organising of code, tools and publishing and includes Paket.
- Create a
.paketfolder in the root of your solution.
- Download the latest paket.bootstrapper.exe into that folder.
.paket/paket.bootstrapper.exe. This will download the latest
.paket/paket.bootstrapper.exeinto your repo and add
1: 2: 3: 4: 5: 6:
If you use a Paket plugin for your editor, you may get autocompletion for paket.dependencies files.
You can read more about the importance and the structure of the
paket.dependencies file in the docs. This file should be committed to your version control system.
Install all of the required packages from the specified sources:
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19:
You can read more about the
paket.lock file in the docs.
In the last paragraph you learned how to install packages into your repository, but usually you want to use the dependencies in your C#, VB or F# projects.
In order to do so you need a
paket.references files alongside your Visual Studio project files.
By listing the direct dependencies in a
paket.references file, Paket will automatically sync references to the corresponding projects whenever an
update takes place.
1: 2: 3: 4:
Don't forget to run
install again in order to let Paket reference the dependencies in your projects:
Like all of the files above, you should commit
paket.references files to your version control system.
If you want to check if your dependencies have updates you can run the
If you want to update all packages you can use the
If you are already using NuGet and want to learn how to use the automatic NuGet conversion, then read the next tutorial.