Skip to content

Commit

Permalink
Updates docs
Browse files Browse the repository at this point in the history
  • Loading branch information
eMaringolo committed Apr 6, 2020
1 parent f70c031 commit 7b5ab44
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
13 changes: 11 additions & 2 deletions docs/configmaps.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,16 @@ This will produce the a `.configmaps` file with the following STON content:
]
```

**NOTE:** In order to write Applications to disk, such applications must be loaded in the image first. So if your writing a Configuration Map to disk, it is recommended you load the config map first.
### Autoloading

If you attempt to write a Configuration Map that isn't loaded in the image, by default `TonelWriter` will attempt to load it first (and its required maps).

If you want to disable this behavior, you can do it by evaluating:
```smalltalk
aTonelWriter autoLoad: false
```

With the autoloading disabled, if you attempt to write a Configuration Map, an exception will be raised.


## Loading Configuration Maps from disk
Expand All @@ -86,4 +95,4 @@ loader loadAllMapsWithRequiredMaps.

When loading a Configuration Map the _TonelLoader_ will first search for any matching version in the Tonel repository and if not found then it will search it up in the ENVY Library. If no version is found in neither of these, and error will be thrown.

All applications of the Configuration Map read from disk are expected to be in the Tonel repository as well, so there is currently no way to load just the configuration map from disk and the version from the EM Library.
All applications of the Configuration Map read from disk are expected to be in the Tonel repository as well, so there is currently no way to load just the configuration map from disk and the applications from the EM Library.
5 changes: 5 additions & 0 deletions docs/strategies.md
Original file line number Diff line number Diff line change
Expand Up @@ -114,8 +114,13 @@ This will automatically select the latest (newest) edition as the base edition f
aTonelLoader useLatestBaseEditions
```

### `TonelLoaderGitParentBaseEditionStrategy` (unattended)

In git repositories, each commit has one or more parent commits, this strategy will try to find a base edition whose versionName matches the parent commit hash (only its first eight characters), and if no edition is found, it will choose the latest one, as in `TonelLoaderlatestBaseEditionStrategy`.

When setting `useGitVersion` in the `TonelLoader`, this base edition strategy will be set as well.

So if you're loading `MyApplication` from a git repository whose commit id is `8c3fa3d` and parent commit is `b78df32`, when loading a base edition it will look for an edition of `MyApplication` in the EM Library whose `versionName` match `b78df32`.

# Common cases recipes

Expand Down

0 comments on commit 7b5ab44

Please sign in to comment.