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
The `deposit` command iterates over files and directories to build the structure of a rakosh mine in ArangoDB.
9
+
10
+
The files and directories are required to be in a particular layout. The layout is versioned to allow for later changes. See [FS Layout](./8e03a31c-4624-4c1c-bf7c-fb6d9ddbcbae).
11
+
12
+
#### Help Text
13
+
14
+
```text
15
+
rakosh deposit <directory> [options]
16
+
17
+
Deposit content from the filesystem into a mine
18
+
19
+
Positionals:
20
+
directory Directory containing a rakosh mine layout [string] [required]
21
+
22
+
Options:
23
+
--help Show help [boolean]
24
+
--version Show version number [boolean]
25
+
-v, --verbose Run with verbose output [boolean]
26
+
-r, --replace Replace the existing mine if it exists [boolean] [default: false]
27
+
```
28
+
29
+
#### Example
30
+
31
+
Deposit from a directory called `examples/my-mine` with verbose output and replacing any existing version of `my-mine`:
The extraction command use the data in ArangoDB to generate content various formats.
9
+
10
+
#### Gatsby
11
+
12
+
Currently the only supported extraction format is a Gatsby.js site:
13
+
14
+
```text
15
+
rakosh gatsby <mine> <sitecustom> <directory>
16
+
17
+
Extract the data from a mine into a Gatsby.js site layout
18
+
19
+
Positionals:
20
+
mine The name of the mine to extract [required]
21
+
sitecustom A JSON file for site customizations [string] [required]
22
+
directory Target directory into which to extract the data[string] [required]
23
+
24
+
Options:
25
+
--help Show help [boolean]
26
+
--version Show version number [boolean]
27
+
-v, --verbose Run with verbose output [boolean]
28
+
--build Run the build (use --no-build to not) [boolean] [default: true]
29
+
```
30
+
31
+
##### Example
32
+
33
+
Extract from the `docs` mine, using customizations from `docs/cust-dev.json`, into a directory called `heap`. Run with verbose output and do not run `npm build` for gatsby:
The root node of the graph is called the "adit" -- an entrance to a mine.
11
+
12
+
The directory pointed to by the `rakosh deposit` command must contain a markdown file with the following front matter:
13
+
14
+
```yaml
15
+
---
16
+
_key: adit
17
+
fs_layout: '1.1'
18
+
---
19
+
```
20
+
21
+
`fs_layout` is a version identifier that indicates the layout of these files and directories. The `rakosh` tool checks that it can interpret the given layout.
22
+
23
+
##### Passages And Nuggets
24
+
25
+
Directories become Passages and markdown files become Nuggets. If there is a markdown file with front matter `passage: <directory-name>` then its content will be added to the Passage rather than become a Nugget. This file must be in the same directory as the passage directory.
0 commit comments