Skip to content

Commit 64b3701

Browse files
committed
2 parents 133d9cc + 381b6d5 commit 64b3701

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

README.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,3 +38,22 @@ Shows all available configurations.
3838
## help
3939
Shows all available commands and their description.
4040
- `<name>`: Shows the description of a command by name.
41+
42+
## Requires
43+
If you want to load a library within a program and keep it updated through SCM, then you can do that with the following notation:
44+
45+
```lua
46+
local scm = require("./scm")
47+
scm:load("testLibrary")
48+
```
49+
50+
If the Library is already called by a Programm using this SCM loader, SCM will check all Libraries loaded for these comments:
51+
52+
53+
```lua
54+
--@requires subLibrary
55+
require("subLibrary")
56+
```
57+
58+
The comment tells SCM to look for the sub-library and, if it's not already installed, it will try to download it.
59+
This prevent the programm from Crashing, should SCM not be installed.

0 commit comments

Comments
 (0)