Skip to content

Commit c85ccae

Browse files
committed
Alias and GitHub app
1 parent 5742bbb commit c85ccae

3 files changed

Lines changed: 33 additions & 9 deletions

File tree

‎docs/EN/SettingUpAaps/BrowserBuildAapsBuilder.md‎

Lines changed: 19 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ You will need:
3838

3939
- A **GitHub account** (free). If you don't have one, create it on [github.com](https://github.com/signup) first.
4040
- A **web browser**: Chrome on your phone, or any browser on a computer. Log in to github.com in that browser before you start.
41+
- **GitHub app on your phone?** You can keep it. Some buttons of the setup page then open the app instead of Chrome. Building works in the app, but the app **cannot download** the finished AAPS: [step 6](#aaps-builder-step6) shows how to switch to Chrome for the download.
4142
- Your **existing keystore** (`.jks` file), its password and its alias, if you built AAPS before and want to update it without reinstalling.
4243

4344
```{warning}
@@ -52,7 +53,7 @@ A private repository gets 2000 free GitHub Actions minutes per month, which is e
5253
- **You already have AAPS on your phone, built with a keystore you still have**: choose **I already have a keystore** on the setup page and upload it. Your next build will update AAPS in place.
5354
- **You build AAPS for the first time, or you lost your keystore or its password**: choose **Create a new key**. An app signed with a new key **cannot update** an AAPS signed with another key. You must export your settings, copy the file off your phone, uninstall the old AAPS, install the new one, then import your settings: see [Lost keystore](#troubleshooting_androidstudio-lost-keystore).
5455
55-
Always keep using the same key afterwards. When you create a new key, download the backup the page offers and store it with its password somewhere safe, off your phone.
56+
Always keep using the same key afterwards. When you create a new key, download the backup the page offers and store it with its password and its alias (`aaps`) somewhere safe, off your phone.
5657
```
5758

5859
## Open the setup page
@@ -160,7 +161,13 @@ The page checks the password and the alias on your device. **Keystore OK! Contin
160161

161162
![New key form with the password typed twice](../images/Building-the-App/CI/AapsBuilder41_NewKey.png)
162163

163-
4. Tap **Download backup (aaps-keystore.jks)** and store the file, together with its password, somewhere safe off your phone (for example your own cloud storage). You need it if you ever build AAPS another way. The alias of this key is `aaps`.
164+
4. Tap **Download backup (aaps-keystore.jks)**. Keep these three together, somewhere safe off your phone (for example your own cloud storage):
165+
166+
- the file `aaps-keystore.jks`,
167+
- your password,
168+
- the alias of the key: **`aaps`**.
169+
170+
You need all three if you ever build AAPS another way, for example with Android Studio.
164171

165172
![Key created and the backup box](../images/Building-the-App/CI/AapsBuilder42_KeyCreated.png)
166173

@@ -200,6 +207,8 @@ GitHub shows **Page not found** (404)? The username or repository name in step 1
200207

201208
![GitHub Build AAPS page with the Run workflow button](../images/Building-the-App/CI/AapsBuilder15_BuildPage.png)
202209

210+
If the **GitHub app** opens instead: tap **RUN WORKFLOW**, check the version and the variant, and tap **RUN WORKFLOW** again. Then continue with step 4 below.
211+
203212
2. If GitHub asks, tap the green button to enable workflows.
204213
3. Tap **Run workflow**. A small form opens:
205214
- **Version**: keep `latest` to build the newest AAPS release, or type a release number such as `3.3.2.1`.
@@ -229,9 +238,15 @@ If there is no **Build AAPS** or **Run workflow** button:
229238
**Before every update**, [export your settings](#ExportImportSettings-Automating-Settings-Export) in AAPS and copy the file **off the phone** (Google Drive, Dropbox…). Keep several older exports and the APK files there too, so you can always go back.
230239
```
231240

232-
1. On your phone, open the setup page in **Chrome**, not in the GitHub app: the GitHub app cannot download builds. Log in to github.com if asked.
241+
1. On your phone, open the setup page in **Chrome**. Log in to github.com if asked.
233242
2. Tap **Open my builds**, then the newest build with a green check.
234243

244+
```{admonition} The GitHub app opened instead of Chrome?
245+
:class: note
246+
247+
The GitHub app cannot download builds. In the app, open the newest build, then tap **Artifacts ↗**, or tap the share icon at the top and choose **Chrome**. The build opens in Chrome: continue with the next step there.
248+
```
249+
235250
![Finished build: status Success and 2 artifacts](../images/Building-the-App/CI/AapsBuilder50_RunSummary.png)
236251

237252
3. Scroll down to the build summary and tap the **Download AAPS** link.
@@ -312,6 +327,7 @@ To see why a build failed, open it from **Open my builds** on the setup page: th
312327
- **"Keystore, password or alias is wrong"**: check your keystore's password and alias, then redo steps 3 and 4 of the setup page.
313328
- **"Version … does not exist"**: the version you typed is not an AAPS release. Use `latest`, or check the release number.
314329
- **"Page not found" (404) when the setup page opens GitHub**: the repository name in step 1 of the setup page does not match your repository. Type the exact name.
330+
- **No Download link, or the GitHub app opened**: the GitHub app cannot download builds. Open the build in Chrome as explained in [step 6](#aaps-builder-step6).
315331
- **"Could not read the workflow file"** on the setup page: reload the page and tap the button again. The setup page must be opened from this documentation site.
316332
- **GitHub says the file already exists** when you commit the workflow: your repository already has a workflow. Update it instead, as explained in [Updating AAPS](#aaps-builder-updates).
317333
- **"Google Drive access has expired or was revoked"**: redo [step 7](#aaps-builder-google-drive) and update the `GDRIVE_OAUTH2` secret.

‎docs/EN/_html/aaps-builder.html‎

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,8 @@
9797
.box { background: var(--soft); border-radius: 8px; padding: 12px 14px; margin-top: 12px; }
9898
.secret-row { display: flex; gap: 8px; align-items: center; margin-top: 8px; flex-wrap: wrap; }
9999
code { background: var(--code); padding: 2px 6px; border-radius: 4px; font-size: .92em; word-break: break-all; }
100-
ol.small { padding-left: 20px; margin: 8px 0; }
101-
ol.small li { margin: 4px 0; }
100+
ol.small, ul.small { padding-left: 20px; margin: 8px 0; }
101+
ol.small li, ul.small li { margin: 4px 0; }
102102
.check { display: flex; gap: 8px; align-items: center; font-weight: 400; margin-top: 10px; }
103103
[hidden] { display: none !important; }
104104
footer { color: var(--muted); font-size: .85rem; margin-top: 24px; }
@@ -187,7 +187,13 @@ <h2><span class="num">3</span><span>Your signing key</span></h2>
187187
<div class="msg" id="newMsg"></div>
188188
<div class="box" id="backupBox" hidden>
189189
<p><b>Save a backup of your key!</b></p>
190-
<p>Download the file and keep it somewhere safe (e.g. your own cloud storage) together with the password. You will need it if you ever build AAPS another way.</p>
190+
<p>Download the file. Keep these three together, somewhere safe off your phone (e.g. your own cloud storage):</p>
191+
<ul class="small">
192+
<li>the file <code>aaps-keystore.jks</code></li>
193+
<li>your password</li>
194+
<li>the alias of the key: <b><code>aaps</code></b></li>
195+
</ul>
196+
<p>You will need all three if you ever build AAPS another way, e.g. with Android Studio.</p>
191197
<button class="btn" id="downloadKs">Download backup (aaps-keystore.jks)</button>
192198
</div>
193199
</div>
@@ -217,7 +223,8 @@ <h2><span class="num">4</span><span>Give the key to your repository</span></h2>
217223
<h2><span class="num">5</span><span>Build the app</span></h2>
218224
<ol class="small">
219225
<li><a class="btn" id="openActions" target="_blank" rel="noopener">Open the build page</a>
220-
<p class="muted">Opens: <code class="repoUrl"></code></p></li>
226+
<p class="muted">Opens: <code class="repoUrl"></code></p>
227+
<p class="muted">The GitHub app opened instead? Tap "RUN WORKFLOW", check the version and variant, and tap "RUN WORKFLOW" again.</p></li>
221228
<li>If asked, click the green button to enable workflows.</li>
222229
<li>Click "Run workflow", then the green "Run workflow" button. "latest" builds the newest AAPS version.</li>
223230
<li>Wait about 15–30 minutes. A green check means it is done.</li>
@@ -244,8 +251,9 @@ <h2><span class="num">6</span><span>Install on your phone</span></h2>
244251
<p class="muted" style="margin-bottom:0"><a href="Maintenance/ExportImportSettings.html" target="_blank" rel="noopener">How to export settings</a> · <a href="UsefulLinks/FAQ.html#how-to-organize-my-backups" target="_blank" rel="noopener">AAPS FAQ: how to organize backups</a></p>
245252
</div>
246253
<ol class="small">
247-
<li>Open this page on your phone, in the web browser (Chrome). Not in the GitHub app: it cannot download builds. Log in to github.com if asked.</li>
248-
<li><a class="btn secondary" id="openRuns" target="_blank" rel="noopener">Open my builds</a></li>
254+
<li>Open this page on your phone, in the web browser (Chrome). Log in to github.com if asked.</li>
255+
<li><a class="btn secondary" id="openRuns" target="_blank" rel="noopener">Open my builds</a>
256+
<p class="muted">The GitHub app opened instead? It cannot download builds. In the app, open the newest build and tap "Artifacts ↗", or tap the share icon and choose Chrome. Continue in Chrome.</p></li>
249257
<li>Tap the newest build with a green check ✅.</li>
250258
<li>Scroll down to the build summary and tap the big link "📱 Download AAPS …" (or scroll further down to "Artifacts" and tap aaps-….apk). Scroll with your finger on the text, not on the diagram of the build steps.</li>
251259
<li>When the download is done, tap the file and choose Install. If asked, allow installing apps from this source.</li>
2.09 KB
Loading

0 commit comments

Comments
 (0)