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

141 lines, 103 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## `help` command
73
74When you type [`help`][help] in OSH or YSH, it shows a URL to this reference,
75or text extracted from it.
76
77[help]: chap-builtin-cmd.html#help
78
79## About
80
81[The source files]($oils-src:doc/) for this reference are in Markdown:
82
83 REPO/
84 doc/
85 release-index.md # /release/$VERSION/
86
87 index.md # All Docs on Oils, /release/$VERSION/doc/
88 getting-started.md
89 ...
90
91 ref/
92 index.md # this page, the Oils Reference
93 toc-osh.md # OSH topics
94 toc-ysh.md # YSH topics
95 toc-data.md # Data language topics
96
97 chap-cmd-lang.md # chapter on the command language
98 chap-front-end.md
99 ...
100
101The URLs mirror the source, with minor differences:
102
103 /release/$VERSION/
104 index.html
105 doc/
106 index.html
107 getting-started.html
108 ...
109
110 ref/
111 index.html
112 toc-osh.html
113 toc-ysh.html
114 toc-data.html
115
116 chap-cmd-lang.html
117 chap-front-end.html
118 ...
119
120You can link to topics with internal anchors:
121
122- [chap-cmd-lang.html#simple-command](chap-cmd-lang.html#simple-command)
123- [chap-builtin-cmd.html#compgen](chap-builtin-cmd.html#compgen)
124
125### Terminology
126
127This reference has a 3-level structure:
128
1291. *Chapter* - A big HTML page.
130 - A chapter may apply to OSH, YSH, or both.
1311. *Section* - An `<h2>` heading in a chapter
1321. *Topic* - An `<h3>` heading in a chapter.
133 - It has a **globally unique** name like `doc-comment`, which is used in the
134 `help` builtin.
135 - A topic may apply to OSH, YSH, or both.
136
137More terminology:
138
139- *Table of Contents* - a doc with a dense list of topic links.
140- *Card* - Some topics are exported as `help` builtin "cards". They can be
141 inline text, or a URL pointer. A card may also link to POSIX or bash docs.