Skip to content

Commit cf259b4

Browse files
committed
Variables docs: fix some review comments
Signed-off-by: Mats Wichmann <[email protected]>
1 parent cfb272b commit cf259b4

File tree

2 files changed

+12
-22
lines changed

2 files changed

+12
-22
lines changed

doc/man/scons.xml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4973,9 +4973,6 @@ the &f-link-Environment; function:</para>
49734973
env = Environment(..., variables=vars)
49744974
</programlisting>
49754975

4976-
<para>
4977-
</para>
4978-
49794976
</listitem>
49804977
</varlistentry>
49814978

doc/user/command-line.xml

Lines changed: 12 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@ SPDX-License-Identifier: MIT
2828

2929
<para>
3030

31-
&SCons; provides a number of ways
32-
for you as the build system writer to grant
33-
the ability to control the build execution.
31+
Software builds are rarely completely static,
32+
so &SCons; gives you a number of ways to help control
33+
build execution via instructions on the command line.
3434
The arguments that can be specified on
3535
the command line are broken down into three types:
3636

@@ -70,7 +70,7 @@ SPDX-License-Identifier: MIT
7070
all of the build variable settings from the command line,
7171
as well as a higher-level interface that lets you
7272
define known build variables,
73-
including defining types, default vaules, help text,
73+
including defining types, default values, help text,
7474
and automatic validation,
7575
as well as applying those to a &consenv;.
7676
See <xref linkend="sect-command-line-variables"></xref>, below.
@@ -117,7 +117,7 @@ SPDX-License-Identifier: MIT
117117
</para>
118118

119119
<section id="sect-SCONSFLAGS">
120-
<title>Not Having to Specify Command-Line Options Each Time: the &SCONSFLAGS; Environment Variable</title>
120+
<title>Not Having to Type Command-Line Options Each Time: the &SCONSFLAGS; Environment Variable</title>
121121

122122
<para>
123123

@@ -214,8 +214,8 @@ C:\Users\foo> <userinput>set SCONSFLAGS="-Q"</userinput>
214214

215215
<para>
216216

217-
&SCons; provides the &f-link-GetOption; function
218-
to query the values set by the various command-line options.
217+
The &f-link-GetOption; function
218+
lets you query the values set by the various command-line options.
219219

220220
</para>
221221

@@ -624,7 +624,7 @@ foo.in
624624

625625
<para>
626626

627-
&SCons; lets you define your own command-line options
627+
You can also define your own command-line options
628628
for the project with the &f-link-AddOption; function.
629629
The &AddOption; function takes the same arguments
630630
as the <function>add_option</function> method
@@ -812,13 +812,6 @@ foo.in
812812
This allows you to modify
813813
aspects of your build in response
814814
to specifications on the command line.
815-
(Note that unless you want to require
816-
a variable to <emphasis>always</emphasis>
817-
be specified you probably want to use
818-
the Python dictionary <methodname>get</methodname> method,
819-
which allows you to designate a default value
820-
to be used if there is no specification
821-
on the command line.)
822815

823816
</para>
824817

@@ -876,10 +869,10 @@ prog.c
876869
When you retrieve from the &ARGUMENTS; dictionary,
877870
it is useful to use the &Python; dictionary
878871
<methodname>get</methodname> method,
879-
so you can supply a default value if there is not
880-
one given on the command line. Otherwise, the build
872+
so you can supply a default value if the variable is
873+
not given on the command line. Otherwise, the build
881874
will fail with a <exceptionname>KeyError</exceptionname>
882-
if the user does not supply the build option.
875+
if the variable is not set.
883876
</para>
884877
</listitem>
885878
</itemizedlist>
@@ -1288,7 +1281,7 @@ vars = Variables('custom.py', ARGUMENTS)
12881281
<para>
12891282

12901283
&SCons; provides a number of convenience functions
1291-
that provide pre-made behavior definitions
1284+
that provide behavior definitions
12921285
for various types of command-line build variables.
12931286
These functions all return a tuple which is ready
12941287
to be passed to the &Add; or &AddVariables; method call.

0 commit comments

Comments
 (0)