Skip to content

Commit 0496833

Browse files
authored
Merge pull request #251 from synonymdev/chore/github-setup
Github Setup
2 parents deccb74 + 2f5e50d commit 0496833

File tree

3 files changed

+45
-22
lines changed

3 files changed

+45
-22
lines changed

.github/pull_request_template.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
<!-- Closes | Fixes | Resolves #ISSUE_ID -->
2+
<!-- Brief summary of the PR changes, linking to the related resources (issue/design/bug/etc) if applicable. -->
3+
4+
### Description
5+
6+
<!-- Extended summary of the changes, can be a list. -->
7+
8+
### Preview
9+
10+
<!-- Insert relevant screenshot / recording -->
11+
12+
### QA Notes
13+
14+
<!-- Add testing instructions for the PR reviewer to validate the changes. -->
15+
<!-- List the tests you ran, including regression tests if applicable. -->

README.md

Lines changed: 28 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,28 @@
1-
# Bitkit Android
1+
# Bitkit Android (Native)
22

3-
Bitkit Android Native app.
3+
> [!CAUTION]
4+
> ⚠️This **NOT** the repository of the Bitkit app from the app stores!
5+
> The Bitkit app repository is here: **[github.com/synonymdev/bitkit](https://github.com/synonymdev/bitkit)**
6+
7+
---
8+
9+
## About
10+
11+
This repository contains a **new native Android app** which is **not ready for production**.
412

513
## Prerequisites
614

715
1. Download `google-services.json` to `./app` from FCM Console
8-
2. Run Polar with the default initial network
916

10-
## Dev Tips
17+
## Development
1118

12-
- To communicate from host to emulator use:
13-
`127.0.0.1` and setup port forwarding via ADB, eg. `adb forward tcp:9777 tcp:9777`
14-
- To communicate from emulator to host use:
15-
`10.0.2.2` instead of `localhost`
19+
### References
20+
21+
- For LNURL dev testing see [bitkit-docker](https://github.com/ovitrif/bitkit-docker)
1622

1723
### Linting
1824

19-
This project uses detekt with default ktlint and compose-rules for linting Kotlin and Compose code.
25+
This project uses detekt with default ktlint and compose-rules for android code linting.
2026

2127
Recommended Android Studio plugins:
2228
- EditorConfig
@@ -28,29 +34,32 @@ Recommended Android Studio plugins:
2834
./gradlew detekt # run analysis + formatting check
2935
./gradlew detekt --auto-correct # auto-fix formatting issues
3036
```
31-
Lint reports are generated in: `app/build/reports/detekt/`.
37+
Reports are generated in: `app/build/reports/detekt/`.
3238

3339
## Localization
3440
See repo: https://github.com/synonymdev/bitkit-transifex-sync
3541

36-
## Bitcoin Networks
42+
## Build
43+
44+
### Bitcoin Networks
3745
The build config supports building 3 different apps for the 3 bitcoin networks (mainnet, testnet, regtest) via the 3 build flavors:
38-
- dev flavour = regtest
39-
- mainnet flavour = mainnet
40-
- tnet flavour = testnet
46+
- `dev` flavour = regtest
47+
- `mainnet` flavour = mainnet
48+
- `tnet` flavour = testnet
4149

42-
## Build for Release
50+
### Build for Release
4351

4452
**Prerequisite**: setup the signing config:
45-
- Add the keystore file to root, eg. `./release.keystore`
46-
- Add `keystore.properties` to root of the project (see `keystore.properties.template`)
53+
- Add the keystore file to root dir (i.e. `./release.keystore`)
54+
- Setup `keystore.properties` file in root dir (`cp keystore.properties.template keystore.properties`)
55+
56+
#### Routine:
4757

48-
### Routine:
4958
Increment `versionCode` and `versionName` in `app/build.gradle.kts`, then run:
5059
```sh
5160
./gradlew assembleDevRelease
5261
# ./gradlew assembleRelease # for all flavors
5362
```
5463

55-
APK is generated in `app/build/outputs/apk/_flavor_/release`. (_flavor_ can be any of 'dev', 'mainnet', 'tnet').
64+
APK is generated in `app/build/outputs/apk/_flavor_/release`. (`_flavor_` can be any of 'dev', 'mainnet', 'tnet').
5665
Example for dev: `app/build/outputs/apk/dev/release`

app/src/main/java/to/bitkit/env/Env.kt

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,8 @@ internal object Env {
3737

3838
val vssServerUrl
3939
get() = when (network) {
40-
Network.REGTEST -> "https://bitkit.stag0.blocktank.to/vss"
41-
Network.TESTNET -> "https://bitkit.stag0.blocktank.to/vss"
42-
else -> TODO("${network.name} network not implemented")
40+
Network.BITCOIN -> TODO("VSS not implemented for mainnet")
41+
else -> "https://bitkit.stag0.blocktank.to/vss_rs/"
4342
}
4443

4544
val vssStoreId

0 commit comments

Comments
 (0)