Skip to content

Commit 5cc5a00

Browse files
fweikertcopybara-github
authored andcommitted
Bazel Docs: Move command line reference templates from /site to /docs.
The site directory will be deleted soon since DevSite has been deprecated. PiperOrigin-RevId: 973911832
1 parent 81514cb commit 5cc5a00

4 files changed

Lines changed: 82 additions & 0 deletions

File tree

docs/BUILD

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# Description:
2+
# Bazel's documentation on bazel.build
3+
4+
package(
5+
default_applicable_licenses = ["//:license"],
6+
default_visibility = ["//visibility:private"],
7+
)
8+
9+
licenses(["notice"])

docs/BUILD.bazel

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ licenses(["notice"])
77

88
exports_files(
99
[
10+
"command-line-reference-prefix.html",
11+
"command-line-reference-suffix.html",
1012
"docs/user-manual.md",
1113
],
1214
visibility = [
Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
<html devsite>
2+
<head>
3+
<meta name="project_path" value="/_project.yaml">
4+
<meta name="book_path" value="/_book.yaml">
5+
</head>
6+
<body>
7+
8+
<h1 class="page-title">Command-Line Reference</h1>
9+
10+
{% dynamic setvar source_file "site/command-line-reference-prefix.html" %}
11+
{% include "_buttons.html" %}
12+
13+
<pre>
14+
bazel [&lt;startup options&gt;] &lt;command&gt; [&lt;args&gt;]
15+
</pre>
16+
17+
or
18+
19+
<pre>
20+
bazel [&lt;startup options&gt;] &lt;command&gt; [&lt;args&gt;] -- [&lt;target patterns&gt;]
21+
</pre>
22+
23+
See the <a href="/docs/build#specifying-build-targets">User's Guide</a> for the
24+
target patterns syntax.
25+
26+
<h2>Option Syntax</h2>
27+
28+
<p>
29+
Options can be passed to Bazel in different ways. Options that require a value
30+
can be passed with either an equals sign or a space:
31+
<pre>
32+
--&lt;option&gt;=&lt;value&gt;
33+
--&lt;option&gt; &lt;value&gt;
34+
</pre>
35+
Some options have a single character short form; in that case, the short form
36+
has to be passed with a single dash and a space.
37+
<pre>
38+
-&lt;short_form&gt; &lt;value&gt;
39+
</pre>
40+
</p>
41+
42+
<p>
43+
Boolean options can be enabled as follows:
44+
<pre>
45+
--&lt;option&gt;
46+
--&lt;option&gt;=[true|yes|1]
47+
</pre>
48+
49+
and disabled as follows:
50+
<pre>
51+
--no&lt;option&gt;
52+
--&lt;option&gt;=[false|no|0]
53+
</pre>
54+
</p>
55+
56+
<p>
57+
Tristate options are usually set to automatic by default, and can be
58+
force-enabled as follows:
59+
<pre>
60+
--&lt;option&gt;=[true|yes|1]
61+
</pre>
62+
or force-disabled as follows:
63+
<pre>
64+
--no&lt;option&gt;
65+
--&lt;option&gt;=[false|no|0]
66+
</pre>
67+
</p>
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
2+
<br/><br/><br/><br/>
3+
</body>
4+
</html>

0 commit comments

Comments
 (0)