OILS / doc / ref / index.md View on Github | oilshell.org

144 lines, 104 significant
1---
2title: Oils Reference
3all_docs_url: ..
4css_files: ../../web/base.css ../../web/manual.css ../../web/ref-index.css
5default_highlighter: oils-sh
6preserve_anchor_case: yes
7---
8
9<div class="doc-ref-header">
10
11**Oils Reference** &mdash;
12[OSH](toc-osh.html) | [YSH](toc-ysh.html) | [Data Notation](toc-data.html)
13
14</div>
15
16<style>
17 .highlight {
18 background-color: #eee;
19 padding-top: 0.1em;
20 padding-bottom: 0.1em;
21 padding-left: 1em;
22 padding-right: 1em;
23 /*
24 font-size: 1.2em;
25 */
26 }
27</style>
28
29This reference has **three** tables of contents. They link to topics within 15
30chapters.
31
32<span class="in-progress">(in progress)</span>
33
34<div class="highlight">
35
36[**Data Notation Table of Contents**](toc-data.html)
37
38</div>
39
401. [JSON / J8 Notation](chap-j8.html)
411. [Errors](chap-errors.html)
42
43<div class="highlight">
44
45[**OSH Table of Contents**](toc-osh.html) - Compatible
46
47[**YSH Table of Contents**](toc-ysh.html) - New and Powerful
48
49</div>
50
513. [Types and Methods](chap-type-method.html)
521. [Builtin Functions](chap-builtin-func.html)
531. [Builtin Commands](chap-builtin-cmd.html)
541. [Front End](chap-front-end.html)
551. [Command Language](chap-cmd-lang.html)
561. [Standard Library](chap-stdlib.html)
571. [OSH Assignment](chap-osh-assign.html)
581. [YSH Command Language Keywords](chap-ysh-cmd.html)
591. [Word Language](chap-word-lang.html)
601. [YSH Expression Language](chap-expr-lang.html)
611. [Mini Languages](chap-mini-lang.html)
621. [Global Shell Options](chap-option.html)
631. [Special Variables](chap-special-var.html)
641. [Plugins and Hooks](chap-plugin.html)
65
66<div class="highlight">
67
68[**Index**](chap-index.html)
69
70</div>
71
72[Topics By Feature](feature-index.html) - Modules, Env Vars, etc.
73
74
75## `help` command
76
77When you type [`help`][help] in OSH or YSH, it shows a URL to this reference,
78or text extracted from it.
79
80[help]: chap-builtin-cmd.html#help
81
82## About
83
84[The source files]($oils-src:doc/) for this reference are in Markdown:
85
86 REPO/
87 doc/
88 release-index.md # /release/$VERSION/
89
90 index.md # All Docs on Oils, /release/$VERSION/doc/
91 getting-started.md
92 ...
93
94 ref/
95 index.md # this page, the Oils Reference
96 toc-osh.md # OSH topics
97 toc-ysh.md # YSH topics
98 toc-data.md # Data language topics
99
100 chap-cmd-lang.md # chapter on the command language
101 chap-front-end.md
102 ...
103
104The URLs mirror the source, with minor differences:
105
106 /release/$VERSION/
107 index.html
108 doc/
109 index.html
110 getting-started.html
111 ...
112
113 ref/
114 index.html
115 toc-osh.html
116 toc-ysh.html
117 toc-data.html
118
119 chap-cmd-lang.html
120 chap-front-end.html
121 ...
122
123You can link to topics with internal anchors:
124
125- [chap-cmd-lang.html#simple-command](chap-cmd-lang.html#simple-command)
126- [chap-builtin-cmd.html#compgen](chap-builtin-cmd.html#compgen)
127
128### Terminology
129
130This reference has a 3-level structure:
131
1321. *Chapter* - A big HTML page.
133 - A chapter may apply to OSH, YSH, or both.
1341. *Section* - An `<h2>` heading in a chapter
1351. *Topic* - An `<h3>` heading in a chapter.
136 - It has a **globally unique** name like `doc-comment`, which is used in the
137 `help` builtin.
138 - A topic may apply to OSH, YSH, or both.
139
140More terminology:
141
142- *Table of Contents* - a doc with a dense list of topic links.
143- *Card* - Some topics are exported as `help` builtin "cards". They can be
144 inline text, or a URL pointer. A card may also link to POSIX or bash docs.