Offset 1, 3 lines modified | Offset 1, 3 lines modified | ||
1 | · | 1 | ·14550428aa729027bd66bdb1d46144f2·313044·doc·optional·python-cloup-doc_2.0.0.post1-2_all.deb |
2 | ·87f35eb33130c2541b0992be19c3093e·45964·python·optional·python3-cloup_2.0.0.post1-2_all.deb | 2 | ·87f35eb33130c2541b0992be19c3093e·45964·python·optional·python3-cloup_2.0.0.post1-2_all.deb |
Offset 1, 3 lines modified | Offset 1, 3 lines modified | ||
1 | -rw-r--r--···0········0········0········4·2022-12-08·12:18:30.000000·debian-binary | 1 | -rw-r--r--···0········0········0········4·2022-12-08·12:18:30.000000·debian-binary |
2 | -rw-r--r--···0········0········0·····41 | 2 | -rw-r--r--···0········0········0·····4160·2022-12-08·12:18:30.000000·control.tar.xz |
3 | -rw-r--r--···0········0········0···308 | 3 | -rw-r--r--···0········0········0···308692·2022-12-08·12:18:30.000000·data.tar.xz |
Offset 65, 16 lines modified | Offset 65, 16 lines modified | ||
65 | to·them·by·name.</p> | 65 | to·them·by·name.</p> |
66 | </div></blockquote> | 66 | </div></blockquote> |
67 | <p>Cloup·doesn’t·force·the·Unix·convention·on·you.·<code·class="docutils·literal·notranslate"><span·class="pre">cloup.argument</span></code>·takes·an | 67 | <p>Cloup·doesn’t·force·the·Unix·convention·on·you.·<code·class="docutils·literal·notranslate"><span·class="pre">cloup.argument</span></code>·takes·an |
68 | optional·<code·class="docutils·literal·notranslate"><span·class="pre">help</span></code>·parameter.·If·you·pass·a·non-empty·string·to·at·least·one·of | 68 | optional·<code·class="docutils·literal·notranslate"><span·class="pre">help</span></code>·parameter.·If·you·pass·a·non-empty·string·to·at·least·one·of |
69 | the·arguments·of·a·command,·Cloup·will·print·a·“Positional·arguments”·section | 69 | the·arguments·of·a·command,·Cloup·will·print·a·“Positional·arguments”·section |
70 | just·below·the·command·description.</p> | 70 | just·below·the·command·description.</p> |
71 | <div·class="tabbed-set·docutils"> | 71 | <div·class="tabbed-set·docutils"> |
72 | <input·checked="checked"·id="929b844b-bc98-4b54-a030-c7bc6bdc2d31"·name="d724d4a1-4c40-4c1e-b9ed-c767c5af5e4c"·type="radio"> | ||
73 | < | 72 | <input·checked="checked"·id="e9085057-4157-4894-a380-4330a52bc805"·name="0443839e-cb7b-4c8b-ba29-ce34a93161f4"·type="radio"> |
73 | </input><label·class="tabbed-label"·for="e9085057-4157-4894-a380-4330a52bc805"> | ||
74 | Code</label><div·class="tabbed-content·docutils"> | 74 | Code</label><div·class="tabbed-content·docutils"> |
75 | <div·class="highlight-python·notranslate"><div·class="highlight"><pre><span></span><span·class="kn">from</span>·<span·class="nn">pprint</span>·<span·class="kn">import</span>·<span·class="n">pprint</span> | 75 | <div·class="highlight-python·notranslate"><div·class="highlight"><pre><span></span><span·class="kn">from</span>·<span·class="nn">pprint</span>·<span·class="kn">import</span>·<span·class="n">pprint</span> |
76 | <span·class="kn">import</span>·<span·class="nn">cloup</span> | 76 | <span·class="kn">import</span>·<span·class="nn">cloup</span> |
77 | <span·class="kn">from</span>·<span·class="nn">cloup</span>·<span·class="kn">import</span>·<span·class="n">option</span><span·class="p">,</span>·<span·class="n">option_group</span> | 77 | <span·class="kn">from</span>·<span·class="nn">cloup</span>·<span·class="kn">import</span>·<span·class="n">option</span><span·class="p">,</span>·<span·class="n">option_group</span> |
78 | <span·class="nd">@cloup</span><span·class="o">.</span><span·class="n">command</span><span·class="p">()</span> | 78 | <span·class="nd">@cloup</span><span·class="o">.</span><span·class="n">command</span><span·class="p">()</span> |
79 | <span·class="nd">@cloup</span><span·class="o">.</span><span·class="n">argument</span><span·class="p">(</span><span·class="s1">'input_path'</span><span·class="p">,</span>·<span·class="n">help</span><span·class="o">=</span><span·class="s2">"Input·path"</span><span·class="p">)</span> | 79 | <span·class="nd">@cloup</span><span·class="o">.</span><span·class="n">argument</span><span·class="p">(</span><span·class="s1">'input_path'</span><span·class="p">,</span>·<span·class="n">help</span><span·class="o">=</span><span·class="s2">"Input·path"</span><span·class="p">)</span> |
Offset 89, 16 lines modified | Offset 89, 16 lines modified | ||
89 | <span·class="w">····</span><span·class="sd">"""A·test·program·for·cloup."""</span> | 89 | <span·class="w">····</span><span·class="sd">"""A·test·program·for·cloup."""</span> |
90 | ····<span·class="n">pprint</span><span·class="p">(</span><span·class="n">kwargs</span><span·class="p">,</span>·<span·class="n">indent</span><span·class="o">=</span><span·class="mi">3</span><span·class="p">)</span> | 90 | ····<span·class="n">pprint</span><span·class="p">(</span><span·class="n">kwargs</span><span·class="p">,</span>·<span·class="n">indent</span><span·class="o">=</span><span·class="mi">3</span><span·class="p">)</span> |
91 | <span·class="n">main</span><span·class="p">()</span> | 91 | <span·class="n">main</span><span·class="p">()</span> |
92 | </pre></div> | 92 | </pre></div> |
93 | </div> | 93 | </div> |
94 | </div> | 94 | </div> |
95 | <input·id="76dd1fbc-5c7e-42d0-a561-ac3f7638b3c9"·name="d724d4a1-4c40-4c1e-b9ed-c767c5af5e4c"·type="radio"> | ||
96 | < | 95 | <input·id="c472e556-6409-450d-b3ea-5cf79deb06f9"·name="0443839e-cb7b-4c8b-ba29-ce34a93161f4"·type="radio"> |
96 | </input><label·class="tabbed-label"·for="c472e556-6409-450d-b3ea-5cf79deb06f9"> | ||
97 | Generated·help</label><div·class="tabbed-content·docutils"> | 97 | Generated·help</label><div·class="tabbed-content·docutils"> |
98 | <div·class="highlight-none·notranslate"><div·class="highlight"><pre><span></span>Usage:·example·[OPTIONS]·INPUT_PATH·OUT_PATH | 98 | <div·class="highlight-none·notranslate"><div·class="highlight"><pre><span></span>Usage:·example·[OPTIONS]·INPUT_PATH·OUT_PATH |
99 | ··A·test·program·for·cloup. | 99 | ··A·test·program·for·cloup. |
100 | Positional·arguments: | 100 | Positional·arguments: |
101 | ··INPUT_PATH······Input·path | 101 | ··INPUT_PATH······Input·path |
Offset 282, 16 lines modified | Offset 282, 16 lines modified | ||
282 | <li><p>the·option·description·is·always·printed·below·the·option·name,·with·an·indentation | 282 | <li><p>the·option·description·is·always·printed·below·the·option·name,·with·an·indentation |
283 | increment·of·at·least·3·spaces</p></li> | 283 | increment·of·at·least·3·spaces</p></li> |
284 | <li><p>all·definitions·are·separated·by·an·empty·line.</p></li> | 284 | <li><p>all·definitions·are·separated·by·an·empty·line.</p></li> |
285 | </ul> | 285 | </ul> |
286 | <p>The·following·tabs·compare·the·<code·class="docutils·literal·notranslate"><span·class="pre">--help</span></code>·of·the·manim·example·(“aligned”·and | 286 | <p>The·following·tabs·compare·the·<code·class="docutils·literal·notranslate"><span·class="pre">--help</span></code>·of·the·manim·example·(“aligned”·and |
287 | “non-aligned”·refer·to·the·<code·class="docutils·literal·notranslate"><span·class="pre">align_option_groups</span></code>·argument):</p> | 287 | “non-aligned”·refer·to·the·<code·class="docutils·literal·notranslate"><span·class="pre">align_option_groups</span></code>·argument):</p> |
288 | <div·class="tabbed-set·docutils"> | 288 | <div·class="tabbed-set·docutils"> |
289 | <input·checked="checked"·id="21d9cb36-5fa7-49b0-88a9-6c6f6ef0ec2f"·name="c3f019e1-51fe-4572-9a7a-c87e195fc22a"·type="radio"> | ||
290 | < | 289 | <input·checked="checked"·id="a66b71b2-8f4d-4826-8055-2078cfaf9198"·name="1ecbf9f2-b83a-4408-8789-ce646197b1cd"·type="radio"> |
290 | </input><label·class="tabbed-label"·for="a66b71b2-8f4d-4826-8055-2078cfaf9198"> | ||
291 | Linear·layout</label><div·class="tabbed-content·docutils"> | 291 | Linear·layout</label><div·class="tabbed-content·docutils"> |
292 | <div·class="highlight-none·notranslate"><div·class="highlight"><pre><span></span>Usage:·manim·render·[OPTIONS] | 292 | <div·class="highlight-none·notranslate"><div·class="highlight"><pre><span></span>Usage:·manim·render·[OPTIONS] |
293 | ····················SCRIPT_PATH | 293 | ····················SCRIPT_PATH |
294 | ····················[SCENE_NAMES]... | 294 | ····················[SCENE_NAMES]... |
295 | ··Render·some·or·all·scenes·defined·in·a·Python | 295 | ··Render·some·or·all·scenes·defined·in·a·Python |
296 | ··script. | 296 | ··script. |
Offset 321, 16 lines modified | Offset 321, 16 lines modified | ||
321 | ·····Verbosity·of·CLI·output.·Changes·ffmpeg | 321 | ·····Verbosity·of·CLI·output.·Changes·ffmpeg |
322 | ·····log·level·unless·5+. | 322 | ·····log·level·unless·5+. |
323 | [...] | 323 | [...] |
324 | </pre></div> | 324 | </pre></div> |
325 | </div> | 325 | </div> |
326 | </div> | 326 | </div> |
327 | <input·id="fc81ab1f-5883-449a-8460-3c449cb20764"·name="c3f019e1-51fe-4572-9a7a-c87e195fc22a"·type="radio"> | ||
328 | < | 327 | <input·id="e3ab1dc9-4601-45f0-abb1-8aea98f1dcfd"·name="1ecbf9f2-b83a-4408-8789-ce646197b1cd"·type="radio"> |
328 | </input><label·class="tabbed-label"·for="e3ab1dc9-4601-45f0-abb1-8aea98f1dcfd"> | ||
329 | Standard·layout·(aligned)</label><div·class="tabbed-content·docutils"> | 329 | Standard·layout·(aligned)</label><div·class="tabbed-content·docutils"> |
330 | <div·class="highlight-none·notranslate"><div·class="highlight"><pre><span></span>Usage:·manim·render·[OPTIONS] | 330 | <div·class="highlight-none·notranslate"><div·class="highlight"><pre><span></span>Usage:·manim·render·[OPTIONS] |
331 | ····················SCRIPT_PATH | 331 | ····················SCRIPT_PATH |
332 | ····················[SCENE_NAMES]... | 332 | ····················[SCENE_NAMES]... |
333 | ··Render·some·or·all·scenes·defined·in·a·Python | 333 | ··Render·some·or·all·scenes·defined·in·a·Python |
334 | ··script. | 334 | ··script. |
Offset 363, 16 lines modified | Offset 363, 16 lines modified | ||
363 | ······························ffmpeg·log·level | 363 | ······························ffmpeg·log·level |
364 | ······························unless·5+. | 364 | ······························unless·5+. |
365 | [...] | 365 | [...] |
366 | </pre></div> | 366 | </pre></div> |
367 | </div> | 367 | </div> |
368 | </div> | 368 | </div> |
369 | <input·id="1d26cb41-1603-4e85-bbf3-5bdef4d90b1a"·name="c3f019e1-51fe-4572-9a7a-c87e195fc22a"·type="radio"> | ||
370 | < | 369 | <input·id="f725df87-2537-4f45-a6b9-bfe1b0c43110"·name="1ecbf9f2-b83a-4408-8789-ce646197b1cd"·type="radio"> |
370 | </input><label·class="tabbed-label"·for="f725df87-2537-4f45-a6b9-bfe1b0c43110"> | ||
371 | Standard·layout·(non-aligned)</label><div·class="tabbed-content·docutils"> | 371 | Standard·layout·(non-aligned)</label><div·class="tabbed-content·docutils"> |
372 | <div·class="highlight-none·notranslate"><div·class="highlight"><pre><span></span>Usage:·manim·render·[OPTIONS] | 372 | <div·class="highlight-none·notranslate"><div·class="highlight"><pre><span></span>Usage:·manim·render·[OPTIONS] |
373 | ····················SCRIPT_PATH | 373 | ····················SCRIPT_PATH |
374 | ····················[SCENE_NAMES]... | 374 | ····················[SCENE_NAMES]... |
375 | ··Render·some·or·all·scenes·defined·in·a·Python | 375 | ··Render·some·or·all·scenes·defined·in·a·Python |
376 | ··script. | 376 | ··script. |
Offset 85, 16 lines modified | Offset 85, 16 lines modified | ||
85 | a·description·of·the·constraint·will·be·shown·between·squared·brackets | 85 | a·description·of·the·constraint·will·be·shown·between·squared·brackets |
86 | aside·the·option·group·title·(or·below·it·if·too·long)</p></li> | 86 | aside·the·option·group·title·(or·below·it·if·too·long)</p></li> |
87 | <li><p><strong>hidden</strong>·– | 87 | <li><p><strong>hidden</strong>·– |
88 | if·True,·the·option·group·and·all·its·options·are·hidden·from·the·help·page | 88 | if·True,·the·option·group·and·all·its·options·are·hidden·from·the·help·page |
89 | (all·contained·options·will·have·their·hidden·attribute·set·to·True).</p></li> | 89 | (all·contained·options·will·have·their·hidden·attribute·set·to·True).</p></li> |
90 | </ul> | 90 | </ul> |
91 | <div·class="tabbed-set·docutils"> | 91 | <div·class="tabbed-set·docutils"> |
92 | <input·checked="checked"·id="ba59c2d6-b866-4555-8be4-ff804e7813fe"·name="cbe0d372-ffcd-4f5f-934f-c97faf6f1aec"·type="radio"> | ||
93 | < | 92 | <input·checked="checked"·id="bdc75115-cacd-472a-94ea-2adce591cac8"·name="3285787b-bade-4425-9e9c-ddc9b260bda3"·type="radio"> |
93 | </input><label·class="tabbed-label"·for="bdc75115-cacd-472a-94ea-2adce591cac8"> | ||
94 | Code</label><div·class="tabbed-content·docutils"> | 94 | Code</label><div·class="tabbed-content·docutils"> |
95 | <div·class="highlight-python·notranslate"><div·class="highlight"><pre><span></span><span·class="kn">import</span>·<span·class="nn">cloup</span> | 95 | <div·class="highlight-python·notranslate"><div·class="highlight"><pre><span></span><span·class="kn">import</span>·<span·class="nn">cloup</span> |
96 | <span·class="kn">from</span>·<span·class="nn">cloup</span>·<span·class="kn">import</span>·<span·class="n">option_group</span><span·class="p">,</span>·<span·class="n">option</span> | 96 | <span·class="kn">from</span>·<span·class="nn">cloup</span>·<span·class="kn">import</span>·<span·class="n">option_group</span><span·class="p">,</span>·<span·class="n">option</span> |
97 | <span·class="kn">from</span>·<span·class="nn">cloup.constraints</span>·<span·class="kn">import</span>·<span·class="n">RequireAtLeast</span> | 97 | <span·class="kn">from</span>·<span·class="nn">cloup.constraints</span>·<span·class="kn">import</span>·<span·class="n">RequireAtLeast</span> |
98 | <span·class="nd">@cloup</span><span·class="o">.</span><span·class="n">command</span><span·class="p">()</span> | 98 | <span·class="nd">@cloup</span><span·class="o">.</span><span·class="n">command</span><span·class="p">()</span> |
99 | <span·class="nd">@option_group</span><span·class="p">(</span> | 99 | <span·class="nd">@option_group</span><span·class="p">(</span> |
Offset 118, 16 lines modified | Offset 118, 16 lines modified | ||
118 | <span·class="w">····</span><span·class="sd">"""·A·CLI·that·does·nothing.·"""</span> | 118 | <span·class="w">····</span><span·class="sd">"""·A·CLI·that·does·nothing.·"""</span> |
119 | ····<span·class="nb">print</span><span·class="p">(</span><span·class="n">kwargs</span><span·class="p">)</span> | 119 | ····<span·class="nb">print</span><span·class="p">(</span><span·class="n">kwargs</span><span·class="p">)</span> |
120 | <span·class="n">cli</span><span·class="p">()</span> | 120 | <span·class="n">cli</span><span·class="p">()</span> |
121 | </pre></div> | 121 | </pre></div> |
122 | </div> | 122 | </div> |
123 | </div> | 123 | </div> |
124 | <input·id="d1a1c6f9-f806-42b8-b88c-aa210e3d14d5"·name="cbe0d372-ffcd-4f5f-934f-c97faf6f1aec"·type="radio"> | ||
125 | < | 124 | <input·id="edaa7f0b-a99d-4289-a177-494742789ce5"·name="3285787b-bade-4425-9e9c-ddc9b260bda3"·type="radio"> |
125 | </input><label·class="tabbed-label"·for="edaa7f0b-a99d-4289-a177-494742789ce5"> | ||
126 | Generated·help</label><div·class="tabbed-content·docutils"> | 126 | Generated·help</label><div·class="tabbed-content·docutils"> |
127 | <div·class="highlight-none·notranslate"><div·class="highlight"><pre><span></span>Usage:·clouptest·[OPTIONS] | 127 | <div·class="highlight-none·notranslate"><div·class="highlight"><pre><span></span>Usage:·clouptest·[OPTIONS] |
128 | ··A·CLI·that·does·nothing. | 128 | ··A·CLI·that·does·nothing. |
129 | Input·options: | 129 | Input·options: |
130 | ··--one·TEXT··········1st·input·option | 130 | ··--one·TEXT··········1st·input·option |
Offset 168, 16 lines modified | Offset 168, 16 lines modified | ||
168 | <p>By·default,·all·option·group·help·sections·are·<strong>aligned</strong>,·meaning·that·they | 168 | <p>By·default,·all·option·group·help·sections·are·<strong>aligned</strong>,·meaning·that·they |
169 | share·the·same·column·widths.·Many·people·find·this·visually·pleasing·and·this | 169 | share·the·same·column·widths.·Many·people·find·this·visually·pleasing·and·this |
170 | is·also·the·default·behavior·of·<code·class="docutils·literal·notranslate"><span·class="pre">argparse</span></code>.</p> | 170 | is·also·the·default·behavior·of·<code·class="docutils·literal·notranslate"><span·class="pre">argparse</span></code>.</p> |
171 | <p>Nonetheless,·if·some·of·your·option·groups·have·shorter·options,·alignment·may | 171 | <p>Nonetheless,·if·some·of·your·option·groups·have·shorter·options,·alignment·may |
172 | result·in·a·lot·of·wasted·space·and·definitions·quite·far·from·option·names, | 172 | result·in·a·lot·of·wasted·space·and·definitions·quite·far·from·option·names, |
173 | which·is·bad·for·readability.·See·this·biased·example·to·compare·the·two·modes:</p> | 173 | which·is·bad·for·readability.·See·this·biased·example·to·compare·the·two·modes:</p> |
174 | <div·class="tabbed-set·docutils"> | 174 | <div·class="tabbed-set·docutils"> |
175 | <input·checked="checked"·id="7e644825-eb71-4ab4-8aff-89bd695f64ee"·name="03a9664d-0754-4d2e-9b61-b68e13f0e7f8"·type="radio"> | ||
176 | < | 175 | <input·checked="checked"·id="c1dd9639-09db-4b4f-94c0-c27a0d4ec4fa"·name="3fa6b246-c5ec-46e7-babc-878b3e2f679c"·type="radio"> |
176 | </input><label·class="tabbed-label"·for="c1dd9639-09db-4b4f-94c0-c27a0d4ec4fa"> | ||
177 | Aligned</label><div·class="tabbed-content·docutils"> | 177 | Aligned</label><div·class="tabbed-content·docutils"> |
178 | <div·class="highlight-none·notranslate"><div·class="highlight"><pre><span></span>Usage:·clouptest·[OPTIONS] | 178 | <div·class="highlight-none·notranslate"><div·class="highlight"><pre><span></span>Usage:·clouptest·[OPTIONS] |
179 | ··A·CLI·that·does·nothing. | 179 | ··A·CLI·that·does·nothing. |
180 | Input·options: | 180 | Input·options: |
181 | ··--one·TEXT···················This·description·is·more·likely·to·be·wrapped | 181 | ··--one·TEXT···················This·description·is·more·likely·to·be·wrapped |
Offset 198, 16 lines modified | Offset 198, 16 lines modified | ||
198 | Other·options: | 198 | Other·options: |
199 | ··--seven·[a|b|c|d|e|f|g|h|i]··First·uncategorized·option. | 199 | ··--seven·[a|b|c|d|e|f|g|h|i]··First·uncategorized·option. |
200 | ··--height·TEXT················Second·uncategorized·option. | 200 | ··--height·TEXT················Second·uncategorized·option. |
201 | ··--help·······················Show·this·message·and·exit. | 201 | ··--help·······················Show·this·message·and·exit. |
202 | </pre></div> | 202 | </pre></div> |
203 | </div> | 203 | </div> |
204 | </div> | 204 | </div> |
205 | <input·id="0f3070ec-9a10-4a82-8895-ee9bef23dbfc"·name="03a9664d-0754-4d2e-9b61-b68e13f0e7f8"·type="radio"> | ||
206 | < | 205 | <input·id="4faad4a2-0457-4c07-b25a-2d63a0235fcc"·name="3fa6b246-c5ec-46e7-babc-878b3e2f679c"·type="radio"> |
206 | </input><label·class="tabbed-label"·for="4faad4a2-0457-4c07-b25a-2d63a0235fcc"> | ||
207 | Non-aligned</label><div·class="tabbed-content·docutils"> | 207 | Non-aligned</label><div·class="tabbed-content·docutils"> |
208 | <div·class="highlight-none·notranslate"><div·class="highlight"><pre><span></span>Usage:·clouptest·[OPTIONS] | 208 | <div·class="highlight-none·notranslate"><div·class="highlight"><pre><span></span>Usage:·clouptest·[OPTIONS] |
209 | ··A·CLI·that·does·nothing. | 209 | ··A·CLI·that·does·nothing. |
210 | Input·options: | 210 | Input·options: |
211 | ··--one·TEXT····This·description·is·more·likely·to·be·wrapped·when·aligning. | 211 | ··--one·TEXT····This·description·is·more·likely·to·be·wrapped·when·aligning. |
Offset 72, 16 lines modified | Offset 72, 16 lines modified | ||
72 | <section·id="adding-full-sections"> | 72 | <section·id="adding-full-sections"> |
73 | <h2>Adding·full·sections<a·class="headerlink"·href="#adding-full-sections"·title="Permalink·to·this·heading">¶</a></h2> | 73 | <h2>Adding·full·sections<a·class="headerlink"·href="#adding-full-sections"·title="Permalink·to·this·heading">¶</a></h2> |
74 | <p>This·is·my·favourite·way·of·structuring·my·sections. | 74 | <p>This·is·my·favourite·way·of·structuring·my·sections. |
75 | You·can·find·a·runnable·example·that·implements·part·of·the·help·of·Git | 75 | You·can·find·a·runnable·example·that·implements·part·of·the·help·of·Git |
76 | <a·class="reference·external"·href="https://github.com/janLuke/cloup/blob/master/examples/git_sections.py">here</a>. | 76 | <a·class="reference·external"·href="https://github.com/janLuke/cloup/blob/master/examples/git_sections.py">here</a>. |
77 | The·code·below·is·based·on·that·example.</p> | 77 | The·code·below·is·based·on·that·example.</p> |
78 | <div·class="tabbed-set·docutils"> | 78 | <div·class="tabbed-set·docutils"> |
79 | <input·checked="checked"·id="138a9b87-84cd-4931-a144-3ba85aa91ac3"·name="21e9f192-0977-4d99-884a-37ba936636b0"·type="radio"> | ||
80 | < | 79 | <input·checked="checked"·id="14ac7801-e683-4779-b4ad-9d21e5dab0ea"·name="b51ebefc-1760-4961-9114-12df052b6968"·type="radio"> |
80 | </input><label·class="tabbed-label"·for="14ac7801-e683-4779-b4ad-9d21e5dab0ea"> | ||
81 | Code</label><div·class="tabbed-content·docutils"> | 81 | Code</label><div·class="tabbed-content·docutils"> |
82 | <div·class="highlight-python·notranslate"><div·class="highlight"><pre><span></span><span·class="kn">import</span>·<span·class="nn">cloup</span> | 82 | <div·class="highlight-python·notranslate"><div·class="highlight"><pre><span></span><span·class="kn">import</span>·<span·class="nn">cloup</span> |
83 | <span·class="kn">from</span>·<span·class="nn">.commands</span>·<span·class="kn">import</span>·<span·class="p">(</span>··<span·class="c1">#·import·your·subcommands</span> | 83 | <span·class="kn">from</span>·<span·class="nn">.commands</span>·<span·class="kn">import</span>·<span·class="p">(</span>··<span·class="c1">#·import·your·subcommands</span> |
84 | ····<span·class="n">git_clone</span><span·class="p">,</span>·<span·class="n">git_init</span><span·class="p">,</span>·<span·class="n">git_rm</span><span·class="p">,</span>·<span·class="n">git_sparse_checkout</span><span·class="p">,</span>·<span·class="n">git_mv</span><span·class="p">,</span> | 84 | ····<span·class="n">git_clone</span><span·class="p">,</span>·<span·class="n">git_init</span><span·class="p">,</span>·<span·class="n">git_rm</span><span·class="p">,</span>·<span·class="n">git_sparse_checkout</span><span·class="p">,</span>·<span·class="n">git_mv</span><span·class="p">,</span> |
85 | ····<span·class="n">git_status</span><span·class="p">,</span>·<span·class="n">git_log</span><span·class="p">)</span> | 85 | ····<span·class="n">git_status</span><span·class="p">,</span>·<span·class="n">git_log</span><span·class="p">)</span> |
86 | <span·class="nd">@cloup</span><span·class="o">.</span><span·class="n">group</span><span·class="p">(</span><span·class="s1">'git'</span><span·class="p">)</span> | 86 | <span·class="nd">@cloup</span><span·class="o">.</span><span·class="n">group</span><span·class="p">(</span><span·class="s1">'git'</span><span·class="p">)</span> |
Offset 102, 16 lines modified | Offset 102, 16 lines modified | ||
102 | <span·class="c1">#·Subcommands·that·are·not·assigned·to·a·specific·section</span> | 102 | <span·class="c1">#·Subcommands·that·are·not·assigned·to·a·specific·section</span> |
103 | <span·class="c1">#·populate·the·"default·section"</span> | 103 | <span·class="c1">#·populate·the·"default·section"</span> |
104 | <span·class="n">git</span><span·class="o">.</span><span·class="n">add_command</span><span·class="p">(</span><span·class="n">git_status</span><span·class="p">)</span> | 104 | <span·class="n">git</span><span·class="o">.</span><span·class="n">add_command</span><span·class="p">(</span><span·class="n">git_status</span><span·class="p">)</span> |
105 | <span·class="n">git</span><span·class="o">.</span><span·class="n">add_command</span><span·class="p">(</span><span·class="n">git_log</span><span·class="p">)</span> | 105 | <span·class="n">git</span><span·class="o">.</span><span·class="n">add_command</span><span·class="p">(</span><span·class="n">git_log</span><span·class="p">)</span> |
106 | </pre></div> | 106 | </pre></div> |
107 | </div> | 107 | </div> |
108 | </div> | 108 | </div> |
109 | <input·id="a4906423-a139-4d49-a3c1-722ba4e1e399"·name="21e9f192-0977-4d99-884a-37ba936636b0"·type="radio"> | ||
110 | < | 109 | <input·id="59ba8c63-6ffc-4839-8e86-797dfeb86ec1"·name="b51ebefc-1760-4961-9114-12df052b6968"·type="radio"> |
110 | </input><label·class="tabbed-label"·for="59ba8c63-6ffc-4839-8e86-797dfeb86ec1"> | ||
111 | Generated·help</label><div·class="tabbed-content·docutils"> | 111 | Generated·help</label><div·class="tabbed-content·docutils"> |
112 | <div·class="highlight-none·notranslate"><div·class="highlight"><pre><span></span>Usage:·git·[OPTIONS]·COMMAND·[ARGS]... | 112 | <div·class="highlight-none·notranslate"><div·class="highlight"><pre><span></span>Usage:·git·[OPTIONS]·COMMAND·[ARGS]... |
113 | Options: | 113 | Options: |
114 | ··--help··Show·this·message·and·exit. | 114 | ··--help··Show·this·message·and·exit. |
115 | Start·a·working·area·(see·also:·git·help·tutorial): | 115 | Start·a·working·area·(see·also:·git·help·tutorial): |