You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/environments.md
+6-2Lines changed: 6 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,13 +11,15 @@ If you have many projects, you might notice that older projects require specific
11
11
`Bonsai` addresses these problems by supporting the creation of reproducible package environments. An environment is a self-contained, portable, installation of `Bonsai` that records a *snapshot* of all the packages required to run the workflows in your project. This makes it much easier to share a project with other people, or keep track of multiple separate projects in your local machine, and be assured you always have everything you need in the right place.
12
12
13
13
## Environment Basics
14
+
14
15
The key to creating and updating environments is the `Bonsai.config` file, which keeps a record of all currently installed dependencies for a specific Bonsai setup. You can find this file in the same location of the Bonsai executable (`Bonsai.exe`). Anytime you install or update a package, Bonsai will automatically modify the config file.
15
16
16
17
The contents of the `Bonsai.config` file are compared with the current state of the `Packages` folder when Bonsai starts. If there are any missing packages the Bonsai bootstrapper will download them automatically to recover the expected state of the installation folder.
17
18
18
19
There is a second configuration file located next to the `Bonsai.config` file called `NuGet.config`. This file stores a list of all the remote, and local, NuGet package sources where the [`Package Manager`](xref:packages) should look for new packages. While this file needs to be included in the environment, most users do not need to modify it.
19
20
20
21
## Portable Method
22
+
21
23
> [!TIP]
22
24
> We recommend this approach for the casual user.
23
25
@@ -46,7 +48,7 @@ We have also provided a command-line tool for "one-click" deployment which insta
46
48
47
49
1. Download the [Bonsai installer](https://bonsai-rx.org/docs/articles/installation.html).
48
50
2. When running the installer, ensure that **Add to PATH (requires shell restart)** is selected within **Options**.
49
-
3. Navigate to the folder where you want to create a new Bonsai environment and run this command.
51
+
3. Navigate to the folder where you want to create a new Bonsai environment and run this command.
50
52
51
53
```cmd
52
54
bonsai --init
@@ -66,6 +68,7 @@ bonsai --no-editor
66
68
```
67
69
68
70
## Adding Local Dependencies
71
+
69
72
> [!TIP]
70
73
> For [new package](xref:create-package) developers, you may need to install local NuGet packages as dependencies during testing.
71
74
@@ -94,6 +97,7 @@ You can also use relative paths if you want to keep package sources relative to
94
97
Similar to `Bonsai.config` the `NuGet.config` file will be used as part of the bootstrapper process when `Bonsai.exe` starts.
95
98
96
99
## Version Control
100
+
97
101
To keep track of environments, all that is needed are these two files.
98
102
99
103
-`NuGet.config`
@@ -107,4 +111,4 @@ To prevent installed packages and other binary files from being tracked, you can
0 commit comments