Skip to content

Commit 62ec86c

Browse files
authored
Merge pull request #5 from tokejepsen/master
Documentation for list/load projects and asset creation.
2 parents 2fb03e4 + 631498f commit 62ec86c

File tree

1 file changed

+91
-1
lines changed

1 file changed

+91
-1
lines changed

pages/2.0/tutorials.md

Lines changed: 91 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,10 +81,100 @@ The `--init` command is used to write a generic configuration and inventory to y
8181
<br>
8282
<br>
8383

84+
## List your projects
85+
86+
Knowing what projects are in the database can be tricky to remember, so instead you can list them.
87+
88+
<div class="tabs">
89+
<button class="tab cmd" onclick="setTab(event, 'cmd')">
90+
<p>cmd</p><div class="tab-gap"></div>
91+
</button>
92+
<button class="tab bash " onclick="setTab(event, 'bash')">
93+
<p>bash</p><div class="tab-gap"></div>
94+
</button>
95+
</div>
96+
97+
<div class="tab-content cmd bash" markdown="1">
98+
```bash
99+
avalon --ls
100+
```
101+
</div>
102+
103+
<br>
104+
<br>
105+
<br>
106+
107+
## Load your projects
108+
109+
There are two ways of specifying which project to load:
110+
111+
1. Name of the current working directory.
112+
113+
<div class="tabs">
114+
<button class="tab cmd" onclick="setTab(event, 'cmd')">
115+
<p>cmd</p><div class="tab-gap"></div>
116+
</button>
117+
<button class="tab bash " onclick="setTab(event, 'bash')">
118+
<p>bash</p><div class="tab-gap"></div>
119+
</button>
120+
</div>
121+
122+
<div class="tab-content cmd bash" markdown="1">
123+
```bash
124+
mkdir projects
125+
cd projects
126+
mkdir myProject
127+
cd myProject
128+
avalon --load
129+
```
130+
</div>
131+
132+
<br>
133+
<br>
134+
<br>
135+
136+
2. Specify the name when loading a project.
137+
138+
<div class="tabs">
139+
<button class="tab cmd" onclick="setTab(event, 'cmd')">
140+
<p>cmd</p><div class="tab-gap"></div>
141+
</button>
142+
<button class="tab bash " onclick="setTab(event, 'bash')">
143+
<p>bash</p><div class="tab-gap"></div>
144+
</button>
145+
</div>
146+
147+
<div class="tab-content cmd bash" markdown="1">
148+
```bash
149+
mkdir projects
150+
cd projects
151+
mkdir customProjectName
152+
cd customProjectName
153+
avalon --load myProject
154+
```
155+
</div>
156+
157+
<br>
158+
<br>
159+
<br>
160+
161+
84162
## Create your first asset
85163

86164
With a project up and running, how do you actually go about creating assets?
87165

166+
The creation of assets are done by editing the ```inventory.toml```. Here is an example asset:
167+
168+
```toml
169+
[[assets]]
170+
name = "Batman"
171+
label = "The Batman" # (Optional) Nicer name
172+
group = "Character" # (Optional) Visual grouping
173+
icon = "gear" # (Optional) Icon from FontAwesome
174+
```
175+
176+
Once you have edited ```inventory.toml``` and saved to disk, you can save the changes to the database with ```avalon --save```.
177+
178+
<br>
88179
<br>
89180
<br>
90-
<br>

0 commit comments

Comments
 (0)