Skip to content

Commit fc586bb

Browse files
committed
[Docs] Added paket.local usage in README
1 parent 3a41154 commit fc586bb

File tree

1 file changed

+24
-3
lines changed

1 file changed

+24
-3
lines changed

README.md

Lines changed: 24 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ Your project folders structure should be:
119119
# Run all tests
120120
dotnet test
121121
```
122-
2. Genarate the ```.nupkg``` file
122+
2. Generate the ```.nupkg``` file
123123

124124
```bash
125125
# Pack your component to the path nupkg/*.nupkg
@@ -141,7 +141,28 @@ Your project folders structure should be:
141141

142142
## Testing your package locally
143143

144-
### Create a local feed "server"
144+
### Method 1: Use `paket.local` file (_recommended_)
145+
146+
The preferrable option is create a `paket.local` file in your consumer project/application,
147+
and add the source path of your package. The `source` property could be a path that contains a **`.nupkg`** file. In this case, you need build and pack your component first:
148+
149+
**- Build/Pack your component project first**
150+
151+
```bash
152+
# Use Visual Studio: Build => Build Solution
153+
# or use dotnet core CLI
154+
dotnet build
155+
```
156+
157+
**- Create the `paket.local` file in your consumer root solution project/application**
158+
159+
**_paket.local_**
160+
```bash
161+
nuget [my-component-id] -> source [my-component-solution]\[my-component-project]\[nupkg-folder] version [my-component-version]
162+
```
163+
> For more information, see the official documentation: [The paket.local file](https://fsprojects.github.io/Paket/local-file.html)
164+
165+
### Method 2: Create a local feed "server"
145166

146167
1. After [generated the `.nupkg`](#generating-package-nupkg) file, create a folder accessible to you (local directory or network share) as package repo:
147168

@@ -151,7 +172,7 @@ Your project folders structure should be:
151172
nuget add [my-component.{version-number}].nupkg -source [your/local-repo/directory]
152173
```
153174

154-
### Add the package/component to a application
175+
#### Add the package/component to a application
155176

156177
**Using [Paket](https://fsprojects.github.io/Paket/index.html)**
157178

0 commit comments

Comments
 (0)