Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: write setup guide for firefox for android #2870

Merged
merged 5 commits into from
Nov 21, 2023
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions doc/SETUP.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,10 @@

To connect to a remote development LND node you can use a [test account](https://github.com/bumi/lightning-browser-extension/wiki/Test-setup)

## Install and debug extension for Firefox Android

[Refer to SETUP_ANDROID.md for info regarding how to setup and debug Alby on firefox android](./SETUP_ANDROID.md)

### Multiple Extensions

It is not recommended to have multiple versions of the extension (development + official) running in the same browser. You will have instances of the extension with the same icon which is confusing, and also leads to a poor webln experience as both extensions will launch a popup. There may also be unexpected bugs due to conflict with the two extensions running at the same time.
Expand Down
22 changes: 22 additions & 0 deletions doc/SETUP_ANDROID.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Install and debug extension for Firefox Android

a. **Prerequisite**

1. Install or update [web-ext](https://github.com/mozilla/web-ext) to version 4.1.0 or later.
2. Install the [Android Platform Tools](https://developer.android.com/tools/releases/platform-tools) (you can use Android studio's [sdk manager](https://developer.android.com/studio/intro/update.html#sdk-manager) or [sdk manager](https://developer.android.com/tools/sdkmanager) command line tools to install android platform tools)
3. Make sure you have adb installed and in your PATH.

b. **Setup Android Device**

1. Install [Firefox for Android Nightly](https://play.google.com/store/apps/details?id=org.mozilla.fenix) on Android
2. Enable [Android USB debugging](https://developer.android.com/studio/debug/dev-options) on the device.
3. Attach your device to the development computer using a USB cable. When prompted, allow USB debugging for the connection.
4. In the settings view for Firefox for Android Nightly, enable "Remote debugging via USB."
5. Run `$ adb devices` in the command shell to get the device ID

c. **Install and run extension**

1. Remove native messaging permission from extensions manifest (web-ext currently doesn't ignore unsupported permissions. temporarily we need to do this unless we find proper solution)
2. Run extension's local development environment via `$ ALBY_API_URL="https://api.getalby.com" yarn run dev:firefox`
3. Go to extension's dist directory: `dist/development/firefox`
4. In the unzipped dist directory of the extension run `$ web-ext run -t firefox-android --adb-device <your_device_code> --firefox-apk org.mozilla.fenix`
reneaaron marked this conversation as resolved.
Show resolved Hide resolved
Loading