You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
bpo-5680: IDLE: Customize running a module (pythonGH-13763)
The initialize options are 1) add command line options, which are appended to sys.argv as if passed on a real command line, and 2) skip the shell restart. The customization dialog is accessed by a new entry on the Run menu.
<spanid="index-2"></span><h3>Run menu (Editor window only)<aclass="headerlink" href="#run-menu-editor-window-only" title="Permalink to this headline">¶</a></h3>
251
-
<dlclass="docutils">
251
+
<dlclass="docutils"id="python-shell">
252
252
<dt>Python Shell</dt>
253
253
<dd>Open or wake up the Python Shell window.</dd>
254
+
</dl>
255
+
<dlclass="docutils" id="check-module">
254
256
<dt>Check Module</dt>
255
257
<dd>Check the syntax of the module currently open in the Editor window. If the
256
258
module has not been saved IDLE will either prompt the user to save or
257
259
autosave, as selected in the General tab of the Idle Settings dialog. If
258
260
there is a syntax error, the approximate location is indicated in the
259
261
Editor window.</dd>
262
+
</dl>
263
+
<dlclass="docutils" id="run-module">
260
264
<dt>Run Module</dt>
261
-
<dd>Do Check Module (above). If no error, restart the shell to clean the
265
+
<dd>Do <aclass="reference internal" href="#check-module"><spanclass="std std-ref">Check Module</span></a>. If no error, restart the shell to clean the
262
266
environment, then execute the module. Output is displayed in the Shell
263
267
window. Note that output requires use of <codeclass="docutils literal notranslate"><spanclass="pre">print</span></code> or <codeclass="docutils literal notranslate"><spanclass="pre">write</span></code>.
264
268
When execution is complete, the Shell retains focus and displays a prompt.
265
269
At this point, one may interactively explore the result of execution.
266
270
This is similar to executing a file with <codeclass="docutils literal notranslate"><spanclass="pre">python</span><spanclass="pre">-i</span><spanclass="pre">file</span></code> at a command
267
271
line.</dd>
268
272
</dl>
273
+
<dlclass="docutils" id="run-custom">
274
+
<dt>Run… Customized</dt>
275
+
<dd>Same as <aclass="reference internal" href="#run-module"><spanclass="std std-ref">Run Module</span></a>, but run the module with customized
276
+
settings. <em>Command Line Arguments</em> extend <aclass="reference internal" href="sys.html#sys.argv" title="sys.argv"><codeclass="xref py py-data docutils literal notranslate"><spanclass="pre">sys.argv</span></code></a> as if passed
277
+
on a command line. The module can be run in the Shell without restarting.</dd>
0 commit comments