Skip to content

Commit 93829df

Browse files
enricosadamairaw
authored andcommitted
fix f# command line tutorial (dotnet#2403)
fix typos and wrong commands (tested with .net core sdk 1.0.4)
1 parent 0248602 commit 93829df

File tree

1 file changed

+10
-8
lines changed

1 file changed

+10
-8
lines changed

docs/fsharp/tutorials/getting-started/getting-started-command-line.md

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ This article covers how you can get started with using F# on .NET Core. It will
1818

1919
## Prerequisites
2020

21-
To begin, you must install the [.NET Core SDK 1.0 or later)](https://dot.net/core). There is no need to uninstall a previous version of the .NET Core SDK, as it supports side-by-side installations.
21+
To begin, you must install the [.NET Core SDK 1.0 or later](https://dot.net/core). There is no need to uninstall a previous version of the .NET Core SDK, as it supports side-by-side installations.
2222

2323
This article assumes that you know how to use a command line and have a preferred text editor. If you don't already use it, [Visual Studio Code](https://code.visualstudio.com) is a great option as a text editor for F#. To get awesome features like IntelliSense, better syntax highlighting, and more, you can download the [Ionide Extension](https://marketplace.visualstudio.com/items?itemName=Ionide.Ionide-fsharp).
2424

@@ -44,10 +44,10 @@ Change directories to *FSNetCore* and start adding projects to the solution fold
4444
Use the `dotnet new` command, create a Class Library project in the **src** folder named Library.
4545

4646
```bash
47-
dotnet new classlib -lang F# -o src/Library
47+
dotnet new lib -lang F# -o src/Library
4848
```
4949

50-
The folowing directory structure is produced as a result of the command completing:
50+
The following directory structure is produced as a result of the command completing:
5151

5252
```
5353
└── FSNetCore
@@ -72,7 +72,7 @@ let getJsonNetJson value =
7272
Add the Newtonsoft.Json NuGet package to the Library project.
7373

7474
```bash
75-
dotnet add package Newtonsoft.Json
75+
dotnet add src/Library/Library.fsproj package Newtonsoft.Json
7676
```
7777

7878
Add the `Library` project to the `FSNetCore` solution using the `dotnet sln add` command:
@@ -91,7 +91,7 @@ Use the `dotnet new` command, create a Console app in the **src** folder named A
9191
dotnet new console -lang F# -o src/App
9292
```
9393

94-
The folowing directory structure is produced as a result of the command completing:
94+
The following directory structure is produced as a result of the command completing:
9595

9696
```
9797
└── FSNetCore
@@ -122,11 +122,12 @@ let main argv =
122122
0 // return an integer exit code
123123
```
124124

125-
Change directories to the *App* console project and add a reference to the `Library` project using `dotnet add reference`.
125+
Add a reference to the `Library` project using `dotnet add reference`.
126126

127127
```bash
128-
dotnet add reference ../Library/Library.fsproj
128+
dotnet add src/App/App.fsproj reference src/Library/Library.fsproj
129129
```
130+
130131
Add the `App` project to the `FSNetCore` solution using the `dotnet sln add` command:
131132

132133
```bash
@@ -135,9 +136,10 @@ dotnet sln add src/App/App.fsproj
135136

136137
Restore the NuGet dependencies, `dotnet restore` and run `dotnet build` to build the project.
137138

138-
Run the project passing `Hello World` as arguments.
139+
Change directory to the `src/App` console project and run the project passing `Hello World` as arguments.
139140

140141
```bash
142+
cd src/App
141143
dotnet run Hello World
142144
```
143145

0 commit comments

Comments
 (0)