| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -3690,7 +3690,10 @@ <h2 id="subcommands">Subcommands<a class="headerlink" href="#subcommands" title= | |||
| 3690 | 3690 | an iOS release build to App Store Connect. See | |
| 3691 | 3691 | <a href="../../guides/building-for-release/">Building for release</a>.</li> | |
| 3692 | 3692 | <li><code>pn app-id android|ios</code>: print the resolved application id (Android) | |
| 3693 | - or bundle id (iOS), handy for scripts and CI.</li> | ||
| 3693 | + or bundle id (iOS), handy for scripts and CI. Flag: <code>--json</code> to print | ||
| 3694 | + a <code>{"platform": "...", "app_id": "..."}</code> object to stdout for | ||
| 3695 | + scripting; the config | ||
| 3696 | + error goes to stderr instead, and a missing config still exits 1.</li> | ||
| 3694 | 3697 | <li><code>pn clean</code>: remove the local <code>build/</code> directory.</li> | |
| 3695 | 3698 | <li><code>pn --version</code> (<code>-V</code>): print the installed PythonNative version.</li> | |
| 3696 | 3699 | </ul> | |
@@ -3729,7 +3732,7 @@ <h2 id="subcommands">Subcommands<a class="headerlink" href="#subcommands" title= | |||
| 3729 | 3732 | <li><code>pn build android|ios</code>: produce standalone artifacts (signed APK/AAB, | |
| 3730 | 3733 | or an iOS archive/IPA, optionally uploaded to App Store Connect).</li> | |
| 3731 | 3734 | <li><code>pn app-id android|ios</code>: print the resolved application/bundle id | |
| 3732 | - (handy for scripts and CI).</li> | ||
| 3735 | + (handy for scripts and CI), as plain text or as JSON with <code>--json</code>.</li> | ||
| 3733 | 3736 | <li><code>pn clean</code>: remove the local <code>build/</code> directory.</li> | |
| 3734 | 3737 | </ul> | |
| 3735 | 3738 | <p>The heavy lifting lives in the <code>pythonnative.project</code> and | |
@@ -4073,6 +4076,15 @@ <h2 id="pythonnative.cli.pn.app_id_command" class="doc doc-heading"> | |||
| 4073 | 4076 | <div class="doc doc-contents "> | |
| 4074 | 4077 | ||
| 4075 | 4078 | <p>Print the resolved application id (Android) or bundle id (iOS).</p> | |
| 4079 | + <p>With <code>--json</code>, stdout carries one object, | ||
| 4080 | + <code>{"platform": "...", "app_id": "..."}</code>, and nothing else; the config | ||
| 4081 | + error goes to stderr instead so stdout stays parseable. Keys may be | ||
| 4082 | + added to that object later, but none will be removed or renamed, so | ||
| 4083 | + a caller reading <code>app_id</code> keeps working.</p> | ||
| 4084 | + <p>A missing or invalid config still exits 1, with or without the flag. | ||
| 4085 | + That differs from <code>pn devices --json</code>, which exits 0 on an empty | ||
| 4086 | + result, because "no devices" is a valid answer to a query whereas | ||
| 4087 | + an unreadable config means there is no id to report at all.</p> | ||
| 4076 | 4088 | ||
| 4077 | 4089 | ||
| 4078 | 4090 | <p><span class="doc-section-title">Parameters:</span></p> | |
@@ -4095,7 +4107,7 @@ <h2 id="pythonnative.cli.pn.app_id_command" class="doc doc-heading"> | |||
| 4095 | 4107 | </td> | |
| 4096 | 4108 | <td> | |
| 4097 | 4109 | <div class="doc-md-description"> | |
| 4098 | - <p>Parsed namespace with <code>platform</code>.</p> | ||
| 4110 | + <p>Parsed namespace with <code>platform</code> and optional <code>json</code>.</p> | ||
| 4099 | 4111 | </div> | |
| 4100 | 4112 | </td> | |
| 4101 | 4113 | <td> | |
| Back | FazBrowse Home | New Git URL |
0 commit comments