forked from Nexus/nexus
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
aae9bf9655 |
|||
|
1691fa981a |
|||
|
393d03d1b7 |
|||
|
c5cc5a052f |
|||
|
11d74b2b2d |
|||
|
69c392a51f |
|||
|
1689cb1007 |
|||
|
2d8cd4eff2 |
|||
|
7b542d8d1e |
|||
|
f106db5948 |
|||
| af99de75da | |||
|
f1f0fea114 |
|||
|
a4141de01d |
|||
|
ab3b9cc83f |
|||
|
ffbb0ad9e2 |
|||
|
d5f29dc344 |
|||
|
05d25869ef |
|||
|
a09ae01b4e |
|||
|
8aada9a895 |
|||
|
a5711d2ded |
|||
|
ecac985d90 |
|||
|
272241f338 |
|||
|
8692527105 |
|||
|
ac31fbb74d |
|||
|
c658034d3b |
|||
|
995afe1412 |
|||
|
bf2aa50556 |
|||
|
d1aa91fbbd |
|||
|
274256dfe4 |
|||
|
1da836e20d |
|||
|
e609bcebcd |
|||
|
bf8490896c |
|||
|
a229fcc598 |
|||
|
06ba23d3c0 |
|||
|
dbc42b0ec2 |
|||
|
29840d595a |
|||
|
5eed03c10e |
|||
|
ee28ddeddd |
|||
|
b29f801f37 |
|||
|
d61de252fb |
|||
|
a701bc6413 |
|||
|
545fdd1f6b |
|||
|
4061b7b51e |
|||
|
b5fe2d4967 |
|||
|
ea29889e5c |
|||
|
e899bb3929 |
|||
|
7f7bdbf525 |
|||
|
47645ea327 |
|||
|
e382499a2a |
|||
|
033c7f9c05 |
|||
|
256e5fadbe |
|||
|
39b8242867 |
|||
|
28ba67cb59 |
|||
|
a0605a3617 |
|||
|
6d9a8e812b |
|||
|
ecc4618ccd |
|||
|
b201b1159e |
|||
|
029efe7c0a |
|||
|
522df86976 |
|||
|
ff9166966d |
|||
|
20eed13884 |
|||
|
b6c6ac35d9 |
|||
|
a8e045bb3a |
|||
|
b154b4ee2e |
|||
|
b4d5a632dd |
|||
|
2580cc8c1c |
|||
|
2fc5a9bf85 |
|||
|
8650c44266 |
|||
|
3fc33a5ac9 |
|||
|
f35f715b81 |
|||
|
e398043a49 |
|||
|
e9b009d1b9 |
|||
|
641341ed90 |
|||
|
3a8d977f11 |
|||
|
979068fc3a |
|||
|
b55a6e0e83 |
|||
|
7007c9af89 |
|||
|
f6aaf49164 |
|||
|
40f5d0f459 |
|||
|
bcb0c57015 |
|||
|
45b3ec10bf |
|||
|
7baf56adef |
|||
|
51e3fe1007 |
|||
|
9e1d2f6921 |
|||
|
c9172e92eb |
|||
|
cb983701ca |
|||
|
285e6ad76a |
|||
|
cd60163caf |
|||
|
a2638d5c82 |
|||
|
f971c50df0 |
|||
|
1efbc131b4 |
|||
|
4b329b4c6f |
|||
|
2041b81141 |
|||
|
a3ef4f8135 |
|||
|
0a09a4ee0a |
|||
|
62e200f305 |
|||
|
dd01ad9d74 |
|||
|
853116ab2f |
|||
|
53d9c2b1e6 |
|||
|
401b527714 |
|||
|
3754bc2feb |
|||
|
868023a4a1 |
|||
|
9e6951818a |
|||
|
0743c4cfc6 |
|||
|
6336764da0 |
|||
|
3a39f1c5ac |
|||
|
6e2d56ec75 |
|||
|
4e140e9fc7 |
|||
|
e5dd53ed6c |
|||
|
c0f4c053b0 |
|||
|
ee36a9b1c8 |
|||
|
f5371382d7 |
|||
|
2937c241e0 |
|||
|
9dcddb3fbe |
|||
|
3014a9d029 |
|||
|
4a9f151d92 |
|||
|
d4ae5ebccf |
|||
|
850bd33b18 |
|||
|
8fbfcde9c5 |
|||
|
e0b5dc58d0 |
|||
|
ffbf2722f7 |
|||
|
3e1552f246 |
|||
|
44a1ec667e |
|||
|
479279b68e |
|||
|
b0dd452926 |
|||
|
fcfe4eed1e |
|||
|
b390dbbbe1 |
|||
|
8e51852ae3 |
|||
|
48c04d9b3e |
|||
|
7f30150e95 |
|||
|
c8e1aef74b |
|||
|
5ee3449f02 |
|||
|
1715ee785e |
|||
|
e38307657d |
|||
|
e14ab3e708 |
|||
|
f5645db6ea |
|||
|
0fcbc275cd |
|||
|
a54004736b |
|||
|
427e06be3e |
|||
|
a1a15af30d |
|||
| 800fb5566d | |||
|
80197aff00 |
|||
|
78162efbde |
|||
|
a2906746b9 |
|||
|
6659f21ceb |
|||
|
a065b823bb |
|||
|
765e96cce4 |
|||
|
9cf16db669 |
|||
|
2c8a4da2a8 |
|||
|
cb426cd27e |
|||
|
bfd259543d |
|||
|
9f0b80072d |
|||
|
b6ee5aec64 |
|||
|
deac9ef24e |
|||
|
e24e99fd8e |
|||
|
4580110da0 |
|||
|
d1724932b2 |
|||
|
a6fe80fea2 |
|||
|
9f45cbc1e7 |
|||
|
eca2b0b558 |
|||
|
4e6ba571fc |
|||
|
200e03f082 |
|||
|
8180338d99 |
|||
|
72c5e7d819 |
|||
|
254b7e134f |
|||
|
ef25e765d4 |
|||
|
58a27fdd9e |
|||
|
6d42477041 |
|||
|
2f17f5b6c6 |
|||
|
1380233f2e |
|||
|
a3a3781252 |
|||
|
81851bdc42 |
|||
|
f19a51939c |
|||
|
0ad85f24d5 |
|||
|
1c2ba2971b |
|||
|
fb0af571ed |
|||
|
9cd43f4e3c |
|||
|
0fa0f57738 |
|||
|
00f22d46b7 |
|||
|
23046f08a9 |
|||
|
784e5254e2 |
|||
|
7193ac0dba |
|||
|
7ab4b5e59f |
|||
|
c23dc19c6e |
|||
|
0b79aac7af |
|||
|
e4f290eaa6 |
|||
|
d309754c60 |
|||
|
a5dedb0d38 |
|||
|
659e76b8f8 |
|||
|
ab3eda0beb |
|||
|
b71a7f0bd6 |
|||
|
8d944831f5 |
|||
|
9117663c48 |
|||
|
ba258c2fcd |
|||
|
485383e99c |
|||
|
ed84410039 |
|||
|
df592b3f38 |
|||
|
d47c4ae15c |
|||
|
d308ef98cb |
|||
|
f082a75d9c |
|||
|
36f61a62d8 |
|||
|
27137c488d |
|||
|
ce5c7b972b |
|||
|
76d78596cd |
|||
|
ed2d08ed40 |
|||
|
24e516e6dd |
|||
|
66a437094a |
|||
|
d37ec2878b |
|||
|
dbf30c3706 |
|||
|
2d619bf1ad |
|||
|
07700c1eff |
|||
|
a5fef138dd |
|||
|
7353955d4e |
|||
|
012ecd9249 |
|||
|
8fda43ccf8 |
|||
|
3a33bf7bfe |
|||
|
9237a3dbed |
|||
|
30a5fa100c |
|||
|
f198888635 |
|||
|
be945031cd |
|||
|
ad525b338c |
|||
|
0010160714 |
|||
|
f741a6790d |
|||
|
7be1dfe0bc |
|||
|
08dcfdab75 |
|||
|
c81000d6c6 |
|||
|
3c6c610f7c |
|||
|
61c5aa94c2 |
|||
|
02ba9180db |
|||
|
3c6f9f5da2 |
|||
|
1d4af179d4 |
|||
|
9974a6c225 |
|||
|
9c83ae573a |
|||
|
66cfb0e2c6 |
|||
|
02c486e1b3 |
|||
|
b694da31f9 |
|||
|
f931615890 |
|||
|
ae8fa17db3 |
|||
|
a63f4674fd |
|||
|
a46d93dfc5 |
|||
|
294723fdfb |
|||
|
5e3c7ffa68 |
|||
|
1fd9810b83 |
|||
|
d119370816 |
|||
|
ffaa516dcd |
|||
|
e480e6193b |
|||
|
e41efd92c1 |
|||
|
b253fc1d96 |
|||
|
967fe66a1b |
|||
|
658fa562cf |
|||
|
fe33ae2e97 |
|||
|
bcb085c035 |
|||
|
eae79d943d |
|||
|
bdac4a11d7 |
|||
|
2ed2443298 |
|||
|
7f71adab4c |
|||
|
0a3ec830a3 |
|||
|
650f1ac8e4 |
|||
|
af5f238db0 |
|||
|
006008f61d |
|||
|
f23a29e7c1 |
|||
|
493776e3dd |
|||
|
25afcf4acd |
|||
|
e54b059bc9 |
|||
|
b8b074b229 |
|||
|
9ffad93469 |
|||
|
3875c3a14a |
|||
|
a86748e85f |
|||
|
19363baa8d |
|||
|
41bdb04b72 |
|||
|
8da46dffe4 |
|||
|
49f2dc55b8 |
|||
|
f9ff04405f |
|||
|
ecb965994a |
|||
|
36917bbea5 |
|||
|
684d6bad82 |
|||
|
45d69b0b9f |
|||
|
3b2cf6b2a4 |
|||
|
a61cac130b |
|||
|
ec30adc0e3 |
|||
|
a63d182c50 |
|||
|
64a8edda7d |
|||
|
2e85b26511 |
|||
|
a91b45be31 |
|||
|
d9062f68c4 |
|||
|
b3b873ffce |
|||
|
ab69bfe553 |
|||
|
98108d013e |
|||
|
bdf8fc6ce1 |
|||
|
b738c1d0e0 |
|||
|
93b832839b |
|||
|
301bcd94f2 |
|||
|
da7f2dcf4e |
|||
|
b92aaed610 |
|||
|
1e4aab08ad |
|||
| 1c4bf99be2 | |||
|
597112f5d3 |
|||
|
c8b9654219 |
|||
|
9bc2d9955a |
|||
|
ead463262c |
|||
|
281bab0202 |
|||
|
9e024fb6f2 |
|||
|
a0036bdda3 |
|||
|
bd7cd0b10c |
|||
|
ec0934110f |
|||
|
1cfda9c68b |
|||
|
1758815cc9 |
|||
|
9f4702b9d1 |
|||
|
195d212d68 |
|||
|
a698cf8c28 |
|||
|
338d5dfee9 |
|||
|
efa3681816 |
|||
|
3824ca1c13 |
|||
|
01566894a6 |
|||
|
64e548f0c5 |
|||
|
4bde7875fb |
|||
|
07f8e58a4c |
|||
|
a220e27877 |
|||
|
5304f22456 |
|||
|
e5b39507c8 |
|||
|
d37538b69f |
|||
|
e300f4efc9 |
|||
|
bab699658f |
|||
|
1c1f585362 |
|||
|
c90a1c41b0 |
|||
|
9f070fcdba |
|||
|
d712bb3193 |
|||
|
3217c17ea0 |
|||
|
031fbe326c |
|||
|
0149aa2f84 |
|||
|
a1efdb0f46 |
|||
| 389b65ae61 | |||
|
3429a3ed98 |
|||
|
7ab92f76bf |
|||
|
aecfac9533 |
|||
|
c7b89b8e56 |
|||
|
721727d48c |
|||
|
004c3bcd0d |
|||
|
943cd85e22 |
|||
|
09904536e7 |
|||
|
856072e0b0 |
|||
|
110caff170 |
|||
|
eeb2e2f54b |
|||
|
529a2e35c4 |
|||
|
6ad4657d76 |
|||
|
38fd19ad1a |
|||
|
0636366359 |
|||
|
efe9262a97 |
|||
|
2763a0fdf5 |
|||
|
a5da44fdea |
|||
|
ccca02a0bc |
|||
|
721349ca21 |
|||
|
5d994bf2bb |
|||
|
a90bf00f18 |
|||
|
f2efbbeb9f |
|||
|
ed761d6071 |
|||
|
8f35ea2435 |
|||
|
023e75e063 |
|||
|
4d0a4605d6 |
|||
|
faa7292001 |
|||
|
027033ad9e |
|||
|
ece3d16318 |
|||
|
5738239da2 |
|||
|
a2791a6717 |
|||
|
f910d87a23 |
|||
|
f4142859ba |
|||
|
775c77194b |
|||
|
41806be9bf |
|||
|
6e47594a91 |
|||
|
386b3ad1cf |
|||
|
61f2aa7f2a |
|||
|
0c660a98a7 |
|||
|
09534a6775 |
|||
|
0cd815dc79 |
|||
|
800ed0636d |
|||
|
e4cf2a837c |
|||
|
11dca9bf14 |
|||
|
436b8642b3 |
|||
|
269d97be8f |
|||
|
43f70f35a3 |
|||
|
92b148f5b6 |
|||
|
00a42b5f1a |
|||
|
700b4e720f |
|||
|
2a11bcb7e8 |
|||
|
fea39e4191 |
|||
|
deaf564c36 |
|||
|
c0d14ac30e |
|||
|
1a6a5c36ea |
|||
|
35ef82accd |
|||
|
f40dd22277 |
|||
|
1cfea5a819 |
|||
|
b3023d8147 |
|||
|
e8fb3a8523 |
|||
|
0d1ace3fd0 |
|||
|
3d690c26d8 |
|||
|
3fee789c90 |
|||
|
d7c64fea80 |
|||
|
87e7e093f7 |
|||
|
8b7e29ae33 |
|||
|
673c5bd894 |
|||
|
650c62fb99 |
|||
|
4f3b77f9f3 |
|||
|
85bb653980 |
|||
|
a9d2ccbcd1 |
|||
|
73c4a7d07f |
|||
|
57f9498aa3 |
|||
|
cfab803fa0 |
|||
|
f23a35384d |
|||
|
7f7fb451e6 |
|||
|
5d62e66cd9 |
|||
|
009ba504e3 |
|||
|
30b922d390 |
|||
|
63183e0824 |
|||
|
163947fc90 |
|||
|
11457470a0 |
|||
|
dca0b7dd7d |
|||
|
e5dc270f83 |
|||
|
810a0b102b |
|||
|
ec1603b828 |
|||
| 5acdbb5be0 | |||
|
e21c9e8c22 |
|||
|
ea687471bc |
|||
|
8c440447f2 |
|||
|
8ebec15324 |
|||
|
cd8d551e26 |
|||
|
118e5a5826 |
|||
|
6ca9b2a948 |
|||
|
23e01c7a0d |
|||
|
9e7fcdbef7 |
|||
|
9507d69458 |
|||
|
13d90df226 |
|||
|
e925f9657c |
|||
|
b8882d6e48 |
|||
| ff9bf3bec4 | |||
|
6e42902322 |
|||
|
c105a6035c |
|||
|
3d7ef9b32f |
|||
|
51ef66174a |
|||
|
1efb68ebe0 |
|||
|
0a667fda0b |
|||
|
da352cd035 |
|||
|
0201f71e5d |
|||
|
4314c88d5c |
|||
|
88cdcf9863 |
|||
|
e2f25749e0 |
|||
|
47a3d9d92f |
|||
|
a680c5cd0c |
|||
|
0887421f3e |
|||
|
a090d88a23 |
|||
|
32693fb3b5 |
|||
|
4e1f1b64bc |
|||
|
20f1c784f6 |
|||
|
9b79304edc |
|||
|
b797b8de9c |
|||
|
56bb75866c |
|||
|
3baea40669 |
|||
|
2e72ecd559 |
|||
| 077044ec19 | |||
|
01b13b4764 |
|||
|
050e42cc6f |
|||
|
67cee201b6 |
|||
|
2d7b067c93 |
|||
|
a9993013f5 |
|||
|
9c488e8981 |
|||
|
5c16f42d20 |
|||
|
092fc616e6 |
|||
|
6cbf78be6b |
|||
|
68f4bb0c03 |
|||
|
9e24f4cb31 |
|||
|
43d2e94d62 |
|||
|
62fe37c6ae |
|||
|
b9dfbd3ca2 |
|||
|
620440e2a1 |
522 changed files with 28136 additions and 6525 deletions
28
.forgejo/workflows/e2e.yml
Normal file
28
.forgejo/workflows/e2e.yml
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
name: "End-to-end tests"
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: ["main"]
|
||||
pull_request:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
e2e:
|
||||
runs-on: ["large", "debian-13-x86_64"]
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v6
|
||||
with:
|
||||
submodules: recursive
|
||||
|
||||
- name: Lix GHA Installer Action
|
||||
uses: samueldr/lix-gha-installer-action@v2026-02-22
|
||||
with:
|
||||
extra_nix_config: experimental-features = nix-command flakes flake-self-attrs
|
||||
|
||||
- name: Generate code
|
||||
run: nix develop --command bash -c "flutter pub get && dart scripts/generate.dart && flutter pub run build_runner build"
|
||||
|
||||
- name: Run end-to-end tests
|
||||
run: nix run .#e2e-headless
|
||||
60
.github/workflows/android.yml
vendored
60
.github/workflows/android.yml
vendored
|
|
@ -1,39 +1,39 @@
|
|||
name: "Build APK"
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: ["main"]
|
||||
tags: ["*"]
|
||||
workflow_dispatch:
|
||||
push:
|
||||
branches: ["main"]
|
||||
tags: ["*"]
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
build-apk:
|
||||
runs-on: ubuntu-latest
|
||||
build-apk:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v6
|
||||
with:
|
||||
submodules: recursive
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v6
|
||||
with:
|
||||
submodules: recursive
|
||||
|
||||
- name: Lix GHA Installer Action
|
||||
uses: samueldr/lix-gha-installer-action@v2026-02-22
|
||||
with:
|
||||
extra_nix_config: experimental-features = nix-command flakes flake-self-attrs
|
||||
|
||||
- name: Decode keystore
|
||||
run: echo "$KEYSTORE_CONTENT" | base64 --decode > keystore.jks
|
||||
env:
|
||||
KEYSTORE_CONTENT: ${{ secrets.KEYSTORE_CONTENT }}
|
||||
- name: Lix GHA Installer Action
|
||||
uses: samueldr/lix-gha-installer-action@v2026-02-22
|
||||
with:
|
||||
extra_nix_config: experimental-features = nix-command flakes flake-self-attrs
|
||||
|
||||
- name: Build app
|
||||
run: nix develop --command bash -c "flutter pub get && dart scripts/generate.dart && flutter pub run build_runner build && flutter build apk --release"
|
||||
env:
|
||||
KEYSTORE_PATH: ../../keystore.jks
|
||||
KEYSTORE_PASSWORD: ${{ secrets.KEYSTORE_PASSWORD }}
|
||||
- name: Decode keystore
|
||||
run: echo "$KEYSTORE_CONTENT" | base64 --decode > keystore.jks
|
||||
env:
|
||||
KEYSTORE_CONTENT: ${{ secrets.KEYSTORE_CONTENT }}
|
||||
|
||||
- name: Upload installer artifact
|
||||
uses: actions/upload-artifact@v6
|
||||
with:
|
||||
name: APK
|
||||
path: build/app/outputs/flutter-apk/app-release.apk
|
||||
- name: Build app
|
||||
run: nix develop --command bash -c "flutter pub get && dart scripts/generate.dart && flutter pub run build_runner build && flutter build apk --target-platform android-arm64 --split-per-abi --dart-define=GIT_COMMIT=${{ github.sha }}"
|
||||
env:
|
||||
KEYSTORE_PATH: ../../keystore.jks
|
||||
KEYSTORE_PASSWORD: ${{ secrets.KEYSTORE_PASSWORD }}
|
||||
|
||||
- name: Upload installer artifact
|
||||
uses: actions/upload-artifact@v6
|
||||
with:
|
||||
name: APK
|
||||
path: build/app/outputs/flutter-apk/app-arm64-v8a-release.apk
|
||||
|
|
|
|||
92
.github/workflows/flatpak.yml
vendored
92
.github/workflows/flatpak.yml
vendored
|
|
@ -1,37 +1,73 @@
|
|||
name: "Build Flatpaks"
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: ["main"]
|
||||
tags: ["*"]
|
||||
workflow_dispatch:
|
||||
push:
|
||||
branches: ["main"]
|
||||
tags: ["*"]
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
build-flatpak:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- arch: x86_64
|
||||
runner: ubuntu-latest
|
||||
- arch: aarch64
|
||||
runner: ubuntu-24.04-arm
|
||||
runs-on: ${{ matrix.runner }}
|
||||
build-flatpak:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- arch: x86_64
|
||||
runner: ubuntu-latest
|
||||
- arch: aarch64
|
||||
runner: ubuntu-24.04-arm
|
||||
runs-on: ${{ matrix.runner }}
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v6
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v6
|
||||
|
||||
- name: Lix GHA Installer Action
|
||||
uses: samueldr/lix-gha-installer-action@v2026-02-22
|
||||
with:
|
||||
extra_nix_config: experimental-features = nix-command flakes flake-self-attrs
|
||||
- name: Lix GHA Installer Action
|
||||
uses: samueldr/lix-gha-installer-action@v2026-02-22
|
||||
with:
|
||||
extra_nix_config: experimental-features = nix-command flakes flake-self-attrs
|
||||
|
||||
- name: Build app
|
||||
run: nix build .#flatpak
|
||||
- name: Build app
|
||||
run: nix build .#flatpak
|
||||
|
||||
- name: Upload installer artifact
|
||||
uses: actions/upload-artifact@v6
|
||||
with:
|
||||
name: flatpak-${{ matrix.arch }}
|
||||
path: result/nexus.federated.nexus.flatpak
|
||||
- name: Upload installer artifact
|
||||
uses: actions/upload-artifact@v6
|
||||
with:
|
||||
name: flatpak-${{ matrix.arch }}
|
||||
path: result/nexus.federated.nexus.flatpak
|
||||
|
||||
publish:
|
||||
needs: build-flatpak
|
||||
if: github.ref == 'refs/heads/main'
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
pages: write
|
||||
id-token: write
|
||||
environment:
|
||||
name: github-pages
|
||||
url: ${{ steps.deployment.outputs.page_url }}
|
||||
steps:
|
||||
- name: Install flatpak tooling
|
||||
run: sudo apt-get update && sudo apt-get install -y flatpak ostree
|
||||
|
||||
- name: Download bundles
|
||||
uses: actions/download-artifact@v7
|
||||
with:
|
||||
pattern: flatpak-*
|
||||
path: bundles
|
||||
|
||||
- name: Build OSTree repo
|
||||
run: |
|
||||
ostree init --repo=repo --mode=archive-z2
|
||||
for bundle in bundles/*/nexus.federated.nexus.flatpak; do
|
||||
flatpak build-import-bundle repo "$bundle"
|
||||
done
|
||||
flatpak build-update-repo --prune repo
|
||||
|
||||
- uses: actions/upload-pages-artifact@v4
|
||||
with:
|
||||
path: repo
|
||||
|
||||
- name: Deploy to Pages
|
||||
id: deployment
|
||||
uses: actions/deploy-pages@v4
|
||||
|
|
|
|||
4
.github/workflows/ios.yml
vendored
4
.github/workflows/ios.yml
vendored
|
|
@ -19,7 +19,7 @@ jobs:
|
|||
- name: Set up Flutter
|
||||
uses: subosito/flutter-action@v2
|
||||
with:
|
||||
flutter-version: 3.44.4
|
||||
flutter-version: 3.47.4
|
||||
|
||||
- name: Set up Go
|
||||
uses: actions/setup-go@v6
|
||||
|
|
@ -31,7 +31,7 @@ jobs:
|
|||
flutter pub get
|
||||
dart scripts/generate.dart
|
||||
flutter pub run build_runner build
|
||||
flutter build ios --release --no-codesign
|
||||
flutter build ios --no-codesign --dart-define=GIT_COMMIT=${{ github.sha }}
|
||||
|
||||
# Unsigned IPA: SideStore/AltStore re-sign this on-device with the
|
||||
# user's own Apple ID at install time, so no certificate is needed here.
|
||||
|
|
|
|||
19
.github/workflows/macos.yml
vendored
19
.github/workflows/macos.yml
vendored
|
|
@ -19,22 +19,29 @@ jobs:
|
|||
- name: Set up Flutter
|
||||
uses: subosito/flutter-action@v2
|
||||
with:
|
||||
flutter-version: 3.44.4
|
||||
flutter-version: 3.47.4
|
||||
|
||||
- name: Set up Go
|
||||
uses: actions/setup-go@v6
|
||||
with:
|
||||
go-version-file: gomuks/go.mod
|
||||
|
||||
- name: Build app
|
||||
- name: Build App
|
||||
run: |
|
||||
flutter pub get
|
||||
dart scripts/generate.dart
|
||||
flutter pub run build_runner build
|
||||
flutter build macos --release
|
||||
flutter build macos --dart-define=GIT_COMMIT=${{ github.sha }}
|
||||
|
||||
- name: Upload installer artifact
|
||||
- name: Create DMG
|
||||
id: create-dmg
|
||||
uses: L-Super/create-dmg-actions@28511e988b13ca34096d439159a66d468b8e724f
|
||||
with:
|
||||
dmg_name: nexus
|
||||
src_dir: build/macos/Build/Products/Release/Nexus.app
|
||||
|
||||
- name: Upload DMG
|
||||
uses: actions/upload-artifact@v6
|
||||
with:
|
||||
name: Nexus.App
|
||||
path: build/macos/Build/Products/Release/Nexus.app
|
||||
name: nexus.dmg
|
||||
path: ${{ steps.create-dmg.outputs.dmg_path }}
|
||||
|
|
|
|||
109
.github/workflows/windows.yml
vendored
109
.github/workflows/windows.yml
vendored
|
|
@ -1,65 +1,74 @@
|
|||
name: "Build EXE"
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: ["main"]
|
||||
tags: ["*"]
|
||||
workflow_dispatch:
|
||||
push:
|
||||
branches: ["main"]
|
||||
tags: ["*"]
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
build-exe:
|
||||
runs-on: windows-latest
|
||||
build-exe:
|
||||
runs-on: windows-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v6
|
||||
with:
|
||||
submodules: recursive
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v6
|
||||
with:
|
||||
submodules: recursive
|
||||
|
||||
- name: Set up Flutter
|
||||
uses: subosito/flutter-action@v2
|
||||
with:
|
||||
flutter-version: 3.44.4
|
||||
- name: Set up Flutter
|
||||
uses: subosito/flutter-action@v2
|
||||
with:
|
||||
flutter-version: 3.47.4
|
||||
|
||||
- name: Set up Go
|
||||
uses: actions/setup-go@v6
|
||||
with:
|
||||
go-version-file: gomuks/go.mod
|
||||
- name: Set up Go
|
||||
uses: actions/setup-go@v6
|
||||
with:
|
||||
go-version-file: gomuks/go.mod
|
||||
|
||||
- name: Setup MSYS2
|
||||
uses: msys2/setup-msys2@v2
|
||||
with:
|
||||
msystem: MINGW64
|
||||
install: >-
|
||||
mingw-w64-x86_64-gcc
|
||||
- name: Setup MSYS2
|
||||
uses: msys2/setup-msys2@v2
|
||||
with:
|
||||
msystem: CLANG64
|
||||
install: >-
|
||||
mingw-w64-x86_64-gcc
|
||||
|
||||
- name: Go build
|
||||
run: |
|
||||
cd gomuks/pkg/ffi
|
||||
go build -tags goolm,sqlite_fts5 -o ../../../libgomuks.dll -buildmode=c-shared
|
||||
- name: Go build
|
||||
run: |
|
||||
cd gomuks/pkg/ffi
|
||||
go build -tags goolm,sqlite_fts5 -o ../../../libgomuks.dll -buildmode=c-shared
|
||||
|
||||
- name: Build with Flutter
|
||||
run: |
|
||||
flutter pub get
|
||||
dart scripts/generate.dart
|
||||
flutter pub run build_runner build
|
||||
flutter build windows --release
|
||||
- name: Build with Flutter
|
||||
run: |
|
||||
flutter pub get
|
||||
dart scripts/generate.dart
|
||||
flutter pub run build_runner build
|
||||
flutter build windows --dart-define=GIT_COMMIT=${{ github.sha }}
|
||||
|
||||
- name: Copy MinGW runtime DLLs
|
||||
shell: msys2 {0}
|
||||
run: |
|
||||
cp /mingw64/bin/libgcc_s_seh-1.dll build/windows/x64/runner/Release/
|
||||
cp /mingw64/bin/libwinpthread-1.dll build/windows/x64/runner/Release/
|
||||
cp /mingw64/bin/libstdc++-6.dll build/windows/x64/runner/Release/
|
||||
- name: Copy MinGW runtime DLLs
|
||||
shell: msys2 {0}
|
||||
run: |
|
||||
cp /mingw64/bin/libgcc_s_seh-1.dll build/windows/x64/runner/Release/
|
||||
cp /mingw64/bin/libwinpthread-1.dll build/windows/x64/runner/Release/
|
||||
cp /mingw64/bin/libstdc++-6.dll build/windows/x64/runner/Release/
|
||||
|
||||
- name: Install Inno Setup
|
||||
run: choco install innosetup -y
|
||||
- name: Copy MSVC runtime DLLs
|
||||
shell: powershell
|
||||
run: |
|
||||
$release = "build/windows/x64/runner/Release"
|
||||
|
||||
- name: Build Inno Setup installer
|
||||
run: iscc windows/installer.iss
|
||||
Copy-Item C:\Windows\System32\MSVCP140.dll $release -Force
|
||||
Copy-Item C:\Windows\System32\VCRUNTIME140.dll $release -Force
|
||||
Copy-Item C:\Windows\System32\VCRUNTIME140_1.dll $release -Force
|
||||
|
||||
- name: Upload installer artifact
|
||||
uses: actions/upload-artifact@v6
|
||||
with:
|
||||
name: windows-installer
|
||||
path: windows/dist/Nexus-Setup.exe
|
||||
- name: Install Inno Setup
|
||||
run: choco install innosetup -y
|
||||
|
||||
- name: Build Inno Setup installer
|
||||
run: iscc windows/installer.iss
|
||||
|
||||
- name: Upload installer artifact
|
||||
uses: actions/upload-artifact@v6
|
||||
with:
|
||||
name: windows-installer
|
||||
path: windows/dist/Nexus-Setup.exe
|
||||
|
|
|
|||
4
.gitignore
vendored
4
.gitignore
vendored
|
|
@ -41,4 +41,6 @@ key.properties
|
|||
password.txt
|
||||
|
||||
# Nix
|
||||
/result
|
||||
/result
|
||||
# Widget Preview related
|
||||
.widget_preview/
|
||||
|
|
|
|||
2
.gitmodules
vendored
2
.gitmodules
vendored
|
|
@ -1,4 +1,4 @@
|
|||
[submodule "gomuks"]
|
||||
path = gomuks
|
||||
url = https://github.com/gomuks/gomuks
|
||||
branch = main
|
||||
branch = quad/nexus
|
||||
|
|
|
|||
17
.vscode/launch.json
vendored
Normal file
17
.vscode/launch.json
vendored
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
{
|
||||
"configurations": [
|
||||
{
|
||||
"name": "Flutter",
|
||||
"type": "dart",
|
||||
"request": "launch",
|
||||
"program": "lib/main.dart"
|
||||
},
|
||||
{
|
||||
"name": "Flutter (Headless)",
|
||||
"type": "dart",
|
||||
"request": "launch",
|
||||
"program": "lib/main.dart",
|
||||
"env": { "FLUTTER_HEADLESS": "1" }
|
||||
}
|
||||
]
|
||||
}
|
||||
6
.vscode/settings.json
vendored
6
.vscode/settings.json
vendored
|
|
@ -10,7 +10,11 @@
|
|||
"msgtype",
|
||||
"muks",
|
||||
"prefs",
|
||||
"recents",
|
||||
"unban",
|
||||
"unredact"
|
||||
"underride",
|
||||
"unifiedpush",
|
||||
"unredact",
|
||||
"webpush"
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -21,28 +21,32 @@ See [Effective Dart: Style](https://dart.dev/effective-dart/style) for general r
|
|||
Controllers live in `lib/controllers/` and provide a source that exposes data and logic via Riverpod providers, allowing other parts of the code to watch state changes with ref.watch (`ref.watch(MyController.provider)`), access the current value with ref.read (`ref.read(MyController.provider)`), and run helper methods on those classes using the notifier:
|
||||
|
||||
```dart
|
||||
ref.watch(MyController.provider.notifier).helperMethod()
|
||||
ref.read(MyController.provider.notifier).helperMethod()
|
||||
```
|
||||
|
||||
We use an object oriented style for controllers, where `provider` is a static member on the controller class. E.g.
|
||||
|
||||
```dart
|
||||
class MyController extends AsyncNotifier<DataThisControllerExposes> {
|
||||
final SomeInputType input;
|
||||
MyController(this.input);
|
||||
|
||||
class MyController(final SomeInputType input)
|
||||
extends AsyncNotifier<DataThisControllerExposes> {
|
||||
@override
|
||||
Future<DataThisControllerExposes> build() async {
|
||||
return input.foo;
|
||||
}
|
||||
|
||||
static final provider =
|
||||
AsyncNotifierProvider.family<MyController, DataThisControllerExposes, SomeInputType>(
|
||||
AuthorController.new,
|
||||
);
|
||||
AsyncNotifierProvider.family<MyController, DataThisControllerExposes, SomeInputType>(
|
||||
MyController.new,
|
||||
);
|
||||
}
|
||||
```
|
||||
|
||||
#### `watch` vs `read`
|
||||
|
||||
Only use `ref.watch` in a `build` method, where you want to rebuild when the value changes. Everywhere else, like callbacks, `useEffect`, and methods on a controller, use `ref.read`.
|
||||
|
||||
Use `.select` to narrow down what you depend on, e.g. `ref.watch(RoomsController.provider.select((rooms) => rooms[roomId]))`.
|
||||
|
||||
Providers which are not controllers, e.g. they expose no data, only methods, should instead live in `lib/helpers/`. For an example, see `lib/helpers/launch_helper.dart`. Other, non-provider helpers, like extensions or helper methods can also go in `lib/helpers/`.
|
||||
|
||||
### Don't use StatefulWidgets ([Flutter Hooks](https://pub.dev/packages/flutter_hooks))
|
||||
|
|
@ -61,6 +65,36 @@ When possible, use immutable collections instead of the mutable equivalent. For
|
|||
|
||||
When possible, we prefer not to create global variables or methods. You can usually replace a global variable with a Riverpod controller, and a global method with an extension method.
|
||||
|
||||
I'm also not a big fan of unneeded private methods or variables, but this is contextual.
|
||||
|
||||
### Modern Dart syntax
|
||||
|
||||
We try to use newer Dart language features where they make code shorter:
|
||||
|
||||
- Primary constructors for classes, including widgets, e.g. `class const MemberList(final String roomId, {super.key}) extends HookConsumerWidget`.
|
||||
- Dot shorthands wherever the type can be inferred, e.g. `.new(...)`, `padding: .all(8)`, `relationType == .reply`.
|
||||
- Patterns and switch expressions over null checks and casts, e.g. `if (event.content case MessageContent(:final body?))` rather than checking `is` then using `!`.
|
||||
|
||||
### Prefer `map` over inline `for` loops
|
||||
|
||||
When building a list (or set, or map) from another collection, use `.map`, `.expand` and friends rather than a `for` inside the collection literal:
|
||||
|
||||
```dart
|
||||
// Prefer
|
||||
children: rooms.map((room) => RoomTile(room)).toList(),
|
||||
|
||||
// Over
|
||||
children: [for (final room in rooms) RoomTile(room)],
|
||||
```
|
||||
|
||||
Regular `for` statements are fine for logic that doesn't just build a collection.
|
||||
|
||||
### Async values and errors
|
||||
|
||||
When rendering an `AsyncValue`, use the `betterWhen` extension, which shows our standard loading and error widgets, or a switch expression if you need more control (e.g. `AsyncData(:final value) || AsyncLoading(:final value?)` to keep showing old data while reloading).
|
||||
|
||||
For futures started from the UI that nothing awaits, like button presses, add `.onError(showError)` so failures are shown to the user instead of being lost.
|
||||
|
||||
## LLM/AI Assisted Contributions
|
||||
|
||||
LLM generated code is NOT allowed. All contributions should be written by humans. Using LLMs for interacting with others, e.g. for Comments, PRs, etc, is also not allowed.
|
||||
|
|
|
|||
161
README.md
161
README.md
|
|
@ -1,8 +1,5 @@
|
|||
# Nexus Client
|
||||
|
||||
> [!WARNING]
|
||||
> Nexus Client is still in development, and doesn't support everything needed for daily use.
|
||||
|
||||
## Description
|
||||
|
||||
A simple and user-friendly Matrix client made with Flutter and a Gomuks backend.
|
||||
|
|
@ -13,115 +10,63 @@ A simple and user-friendly Matrix client made with Flutter and a Gomuks backend.
|
|||
| :--------------------------------------------------------------------------------------------------------------------------------------------------------------------------: | :------------------------------------------------------------------------------: |
|
||||
|  |  |
|
||||
|
||||
## Progress
|
||||
|
||||
- [x] Platform Support
|
||||
- [x] Linux
|
||||
- [x] Windows - Currently has some bugs, due to us not having any developers on Windows. If you want to fix these, get in contact with us though the [Nexus Client Matrix room](https://matrix.to/#/#nexus:federated.nexus).
|
||||
- [x] Android
|
||||
- [x] MacOS - Unsigned .App only
|
||||
- [x] iOS - Unsigned .ipa only
|
||||
- [ ] Web (may not be possible)
|
||||
- [x] Login (via OAuth)
|
||||
- [x] Rooms / Spaces
|
||||
- [x] Displaying and choosing
|
||||
- [x] Reading, showing unread
|
||||
- [x] Mark as read button on rooms and spaces
|
||||
- [ ] Searching
|
||||
- [ ] Creating (Rooms, Spaces, and DMs)
|
||||
- [x] Joining
|
||||
- [x] Parse vias
|
||||
- [x] Using a text/uri/link
|
||||
- [x] Plain text
|
||||
- [x] `matrix:` Uri
|
||||
- [x] Matrix.to link
|
||||
- [ ] From space
|
||||
- [ ] From directory
|
||||
- [x] Leaving
|
||||
- [x] Subspaces
|
||||
- [x] Messages
|
||||
- [x] Encryption
|
||||
- [x] Restoring crypto identity from a recovery passphrase/key
|
||||
- [x] Sending
|
||||
- [x] Plain text
|
||||
- [x] HTML/Markdown
|
||||
- [x] Replies
|
||||
- [x] Choose ping on/off
|
||||
- [x] Per message profiles
|
||||
- [x] Attachments
|
||||
- [ ] Commands with [MSC4391](https://github.com/matrix-org/matrix-spec-proposals/pull/4391)
|
||||
- [x] Mentions
|
||||
- [x] Users
|
||||
- [x] Rooms
|
||||
- [ ] Inline emoji picker (Putting this here since it'll be implemented the same way as mentions)
|
||||
- [ ] Custom emojis/stickers
|
||||
- [ ] GIFs using Gomuks' GIF proxies
|
||||
- [x] Receiving
|
||||
- [x] Plain text
|
||||
- [x] Per message profiles
|
||||
- [x] HTML
|
||||
- [x] URL Previews
|
||||
- [x] Replies
|
||||
- [x] Viewing
|
||||
- [ ] Jump to original message
|
||||
- [x] In loaded timeline
|
||||
- [ ] Out of loaded timeline
|
||||
- [x] Edits
|
||||
- [x] Attachments
|
||||
- [x] Unencrypted
|
||||
- [x] Encrypted
|
||||
- [x] Blurhashing
|
||||
- [ ] Downloading attachments
|
||||
- [x] Opening attachments in their own view
|
||||
- [ ] Polls
|
||||
- [x] Mentions
|
||||
- [x] Users
|
||||
- [x] Clickable
|
||||
- [x] Rooms
|
||||
- [ ] Clickable
|
||||
- [x] Matrix URIs
|
||||
- [x] Matrix.to links
|
||||
- [x] Events
|
||||
- [ ] Render more nicely
|
||||
- [ ] Clickable
|
||||
- [x] Custom emojis/stickers
|
||||
- [x] History loading
|
||||
- [x] Editing
|
||||
- [x] Deleting
|
||||
- [x] Reactions
|
||||
- [x] Pins
|
||||
- [x] Displaying
|
||||
- [x] Pinning/Unpinning
|
||||
- [ ] Threads
|
||||
- [x] Profile popouts
|
||||
- [x] Working actions
|
||||
- [x] Copy link to:
|
||||
- [x] Room
|
||||
- [x] Space
|
||||
- [x] Message
|
||||
- [ ] Reporting
|
||||
- [x] Events
|
||||
- [ ] Rooms
|
||||
- [x] Member list
|
||||
- [x] Sort by power level
|
||||
- [ ] Colors based off of power level
|
||||
- [ ] Notifications using UnifiedPush ([#35](https://git.federated.nexus/Nexus/nexus/issues/35))
|
||||
- [ ] Group calls using [MSC4195](https://github.com/matrix-org/matrix-spec-proposals/pull/4195)
|
||||
- [ ] Invites
|
||||
- [x] Settings
|
||||
|
||||
## Try it out
|
||||
|
||||
If you want to try out Nexus, grab one of the following artifacts from CI:
|
||||
If you want to try out Nexus, download the [latest release](https://git.federated.nexus/Nexus/nexus/releases/latest).
|
||||
|
||||
### Nightly Builds
|
||||
|
||||
For the newest changes, grab one of the following nightly artifacts, built by CI from the latest commit on `main`.
|
||||
|
||||
- [Android APK](https://nightly.link/Henry-Hiles/nexus/workflows/android/main/APK.zip)
|
||||
- [Windows EXE](https://nightly.link/Henry-Hiles/nexus/workflows/windows/main/windows-installer.zip)
|
||||
- [Unsigned iOS IPA](https://nightly.link/Henry-Hiles/nexus/workflows/ios/main/Nexus.ipa.zip)
|
||||
- [Unsigned MacOS App](https://nightly.link/Henry-Hiles/nexus/workflows/macos/main/Nexus.App.zip)
|
||||
- [Unsigned MacOS DMG](https://nightly.link/Henry-Hiles/nexus/workflows/macos/main/nexus.dmg.zip)
|
||||
- [Windows EXE](https://nightly.link/Henry-Hiles/nexus/workflows/windows/main/windows-installer.zip)
|
||||
- Flatpak
|
||||
- [AArch64/Arm64](https://nightly.link/Henry-Hiles/nexus/workflows/flatpak/main/flatpak-aarch64.zip)
|
||||
- [x86_64/AMD64](https://nightly.link/Henry-Hiles/nexus/workflows/flatpak/main/flatpak-x86_64.zip)
|
||||
|
||||
Or, use one of the below methods:
|
||||
|
||||
### Nightly Flatpak Repo
|
||||
|
||||
Make sure Flatpak is set up on your system, then run:
|
||||
|
||||
```bash
|
||||
flatpak install --user https://nexus.federated.nexus/flatpak/nexus.flatpakref
|
||||
```
|
||||
|
||||
This adds the Nexus remote and installs the app for your user only, so no root access is needed (x86_64 and aarch64 are supported). To install system-wide instead, use `--system` in place of `--user`. Updates arrive through `flatpak update` or your software center.
|
||||
|
||||
### NixOS Module
|
||||
|
||||
Add Nexus as a flake input, following `nixpkgs` for less fetches:
|
||||
|
||||
```nix
|
||||
nexus = {
|
||||
url = "git+https://git.federated.nexus/Nexus/nexus";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
```
|
||||
|
||||
This tracks the latest commit on `main`. To stay on a release instead, pin the input to its tag:
|
||||
|
||||
```nix
|
||||
url = "git+https://git.federated.nexus/Nexus/nexus?ref=refs/tags/v1.0.1";
|
||||
```
|
||||
|
||||
Then import the module and enable it in your NixOS configuration:
|
||||
|
||||
```nix
|
||||
{ inputs, ... }:
|
||||
{
|
||||
imports = [ inputs.nexus.nixosModules.default ];
|
||||
|
||||
programs.nexus = {
|
||||
enable = true;
|
||||
enableNotifications = true; # optional: push notifications via UnifiedPush
|
||||
};
|
||||
}
|
||||
```
|
||||
|
||||
This installs Nexus system-wide. With `enableNotifications`, it also installs KUnifiedPush and registers its systemd and D-Bus services so notifications work. The `package` option lets you override the package if you need to.
|
||||
|
||||
## Build it yourself
|
||||
|
||||
|
|
@ -129,7 +74,7 @@ If you want to try out Nexus, grab one of the following artifacts from CI:
|
|||
|
||||
#### Linux
|
||||
|
||||
- On NixOS: Either use direnv and `direnv allow`, or `nix flake develop`
|
||||
- On NixOS: Either use direnv and `direnv allow`, or `nix develop`
|
||||
- On other distros: Install Flutter, Go, Git, Libclang, Libass, MPV, and Glibc. Do not use any Snap packages, they cause various compilation issues.
|
||||
|
||||
#### Windows
|
||||
|
|
@ -208,7 +153,7 @@ Development instructions can be found in [DEVELOPMENT.md](./DEVELOPMENT.md).
|
|||
|
||||
Join the [Nexus Client Matrix room](https://matrix.to/#/#nexus:federated.nexus) for questions or help with developing or using Nexus Client.
|
||||
|
||||
# Credits
|
||||
## Credits
|
||||
|
||||
Thank you Hylke Bons (https://planetpeanut.studio) for making the amazing icon for Nexus!
|
||||
Thank you Tulir Asokan for making [Gomuks](https://github.com/gomuks/gomuks), and helping us integrate it into Nexus!
|
||||
|
|
|
|||
|
|
@ -1,22 +0,0 @@
|
|||
{
|
||||
"name": "Nexus",
|
||||
"identifier": "nexus.federated.nexus.source",
|
||||
"subtitle": "Nexus for iOS",
|
||||
"description": "Nexus iOS builds for AltStore and SideStore.",
|
||||
"iconURL": "https://git.federated.nexus/Nexus/nexus/raw/branch/main/assets/icon.png",
|
||||
"website": "https://git.federated.nexus/Nexus/nexus",
|
||||
"apps": [
|
||||
{
|
||||
"name": "Nexus",
|
||||
"bundleIdentifier": "nexus.federated.nexus",
|
||||
"developerName": "Nexus",
|
||||
"subtitle": "A Matrix client",
|
||||
"localizedDescription": "Nexus for iOS. Unsigned builds, resigned at install by AltStore/SideStore.",
|
||||
"iconURL": "https://git.federated.nexus/Nexus/nexus/raw/branch/main/assets/icon.png",
|
||||
"category": "social",
|
||||
"screenshots": [],
|
||||
"versions": []
|
||||
}
|
||||
],
|
||||
"news": []
|
||||
}
|
||||
|
|
@ -1,12 +1,18 @@
|
|||
analyzer:
|
||||
errors:
|
||||
invalid_annotation_target: ignore
|
||||
avoid_print: ignore
|
||||
exclude:
|
||||
- "build/**"
|
||||
- "**/*.g.dart"
|
||||
- "**/*.freezed.dart"
|
||||
errors:
|
||||
invalid_annotation_target: ignore
|
||||
avoid_print: ignore
|
||||
exclude:
|
||||
- "build/**"
|
||||
- "**/*.g.dart"
|
||||
- "**/*.freezed.dart"
|
||||
- android/**
|
||||
- ios/**
|
||||
- web/**
|
||||
- windows/**
|
||||
- macos/**
|
||||
- linux/**
|
||||
include: package:flutter_lints/flutter.yaml
|
||||
linter:
|
||||
rules:
|
||||
prefer_double_quotes: true
|
||||
rules:
|
||||
prefer_double_quotes: true
|
||||
|
|
|
|||
|
|
@ -1,77 +0,0 @@
|
|||
plugins {
|
||||
id "com.android.application"
|
||||
id "kotlin-android"
|
||||
// The Flutter Gradle Plugin must be applied after the Android and Kotlin Gradle plugins.
|
||||
id "dev.flutter.flutter-gradle-plugin"
|
||||
}
|
||||
|
||||
def localProperties = new Properties()
|
||||
def localPropertiesFile = rootProject.file("local.properties")
|
||||
if (localPropertiesFile.exists()) {
|
||||
localPropertiesFile.withReader("UTF-8") { reader ->
|
||||
localProperties.load(reader)
|
||||
}
|
||||
}
|
||||
|
||||
def flutterVersionCode = localProperties.getProperty("flutter.versionCode")
|
||||
if (flutterVersionCode == null) {
|
||||
flutterVersionCode = "1"
|
||||
}
|
||||
|
||||
def flutterVersionName = localProperties.getProperty("flutter.versionName")
|
||||
if (flutterVersionName == null) {
|
||||
flutterVersionName = "1.0"
|
||||
}
|
||||
|
||||
def keystoreProperties = new Properties()
|
||||
def keystorePropertiesFile = rootProject.file('key.properties')
|
||||
if (keystorePropertiesFile.exists()) {
|
||||
keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
|
||||
}
|
||||
|
||||
android {
|
||||
namespace = "nexus.federated.nexus"
|
||||
ndkVersion = flutter.ndkVersion
|
||||
compileSdk = 34
|
||||
|
||||
compileOptions {
|
||||
sourceCompatibility = JavaVersion.VERSION_17
|
||||
targetCompatibility = JavaVersion.VERSION_17
|
||||
}
|
||||
|
||||
kotlinOptions {
|
||||
jvmTarget = "17"
|
||||
}
|
||||
|
||||
defaultConfig {
|
||||
applicationId = "nexus.federated.nexus"
|
||||
minSdk = 29
|
||||
targetSdkVersion flutter.targetSdkVersion
|
||||
versionCode = flutterVersionCode.toInteger()
|
||||
versionName = flutterVersionName
|
||||
}
|
||||
|
||||
signingConfigs {
|
||||
release {
|
||||
keyAlias "key"
|
||||
def storePath = keystoreProperties['path'] ?: System.getenv("KEYSTORE_PATH")
|
||||
storeFile storePath ? file(storePath) : null
|
||||
keyPassword keystoreProperties['password'] ?: System.getenv("KEYSTORE_PASSWORD")
|
||||
storePassword keystoreProperties['password'] ?: System.getenv("KEYSTORE_PASSWORD")
|
||||
}
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
signingConfig signingConfigs.release
|
||||
}
|
||||
|
||||
debug {
|
||||
applicationIdSuffix = ".debug"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
flutter {
|
||||
source = "../.."
|
||||
}
|
||||
84
android/app/build.gradle.kts
Normal file
84
android/app/build.gradle.kts
Normal file
|
|
@ -0,0 +1,84 @@
|
|||
import java.util.Properties
|
||||
|
||||
plugins {
|
||||
id("com.android.application")
|
||||
id("dev.flutter.flutter-gradle-plugin")
|
||||
}
|
||||
|
||||
val keystoreProperties = Properties()
|
||||
val keystorePropertiesFile = rootProject.file("key.properties")
|
||||
|
||||
if (keystorePropertiesFile.exists()) {
|
||||
keystorePropertiesFile.inputStream().use {
|
||||
keystoreProperties.load(it)
|
||||
}
|
||||
}
|
||||
|
||||
android {
|
||||
namespace = "nexus.federated.nexus"
|
||||
compileSdk = 36
|
||||
ndkVersion = flutter.ndkVersion
|
||||
|
||||
compileOptions {
|
||||
isCoreLibraryDesugaringEnabled = true
|
||||
sourceCompatibility = JavaVersion.VERSION_21
|
||||
targetCompatibility = JavaVersion.VERSION_21
|
||||
}
|
||||
|
||||
defaultConfig {
|
||||
applicationId = "nexus.federated.nexus"
|
||||
|
||||
minSdk = 29
|
||||
targetSdk = flutter.targetSdkVersion
|
||||
|
||||
versionCode = flutter.versionCode
|
||||
versionName = flutter.versionName
|
||||
|
||||
multiDexEnabled = true
|
||||
}
|
||||
|
||||
signingConfigs {
|
||||
create("release") {
|
||||
keyAlias = "key"
|
||||
|
||||
val storePath =
|
||||
keystoreProperties["path"]?.toString()
|
||||
?: System.getenv("KEYSTORE_PATH")
|
||||
|
||||
storeFile = storePath?.let { file(it) }
|
||||
|
||||
keyPassword =
|
||||
keystoreProperties["password"]?.toString()
|
||||
?: System.getenv("KEYSTORE_PASSWORD")
|
||||
|
||||
storePassword =
|
||||
keystoreProperties["password"]?.toString()
|
||||
?: System.getenv("KEYSTORE_PASSWORD")
|
||||
}
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
signingConfig = signingConfigs.getByName("release")
|
||||
}
|
||||
|
||||
debug {
|
||||
applicationIdSuffix = ".debug"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation("org.unifiedpush.android:embedded-fcm-distributor:3.1.0")
|
||||
coreLibraryDesugaring("com.android.tools:desugar_jdk_libs:2.1.4")
|
||||
}
|
||||
|
||||
kotlin {
|
||||
compilerOptions {
|
||||
jvmTarget = org.jetbrains.kotlin.gradle.dsl.JvmTarget.JVM_21
|
||||
}
|
||||
}
|
||||
|
||||
flutter {
|
||||
source = "../.."
|
||||
}
|
||||
|
|
@ -1,12 +1,16 @@
|
|||
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<uses-permission android:name="android.permission.INTERNET" />
|
||||
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
|
||||
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
|
||||
<uses-permission
|
||||
android:name="android.permission.READ_EXTERNAL_STORAGE"
|
||||
android:maxSdkVersion="32" />
|
||||
<uses-permission
|
||||
android:name="android.permission.WRITE_EXTERNAL_STORAGE"
|
||||
android:maxSdkVersion="29" />
|
||||
<!-- Until https://github.com/flutter/flutter/issues/145290 is fixed, we need enableOnBackInvokedCallback as false -->
|
||||
<application
|
||||
android:enableOnBackInvokedCallback="false"
|
||||
android:label="Nexus"
|
||||
android:name="${applicationName}"
|
||||
android:icon="@mipmap/ic_launcher"
|
||||
|
|
@ -30,6 +34,13 @@
|
|||
|
||||
<data android:scheme="nexus.federated.nexus" />
|
||||
</intent-filter>
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.VIEW" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<category android:name="android.intent.category.BROWSABLE" />
|
||||
|
||||
<data android:scheme="matrix" />
|
||||
</intent-filter>
|
||||
<meta-data
|
||||
android:name="io.flutter.embedding.android.NormalTheme"
|
||||
android:resource="@style/NormalTheme"
|
||||
|
|
@ -49,6 +60,16 @@
|
|||
<meta-data
|
||||
android:name="flutterEmbedding"
|
||||
android:value="2" />
|
||||
<!-- Needed by pasteboard, for pasting files from the clipboard -->
|
||||
<provider
|
||||
android:name="androidx.core.content.FileProvider"
|
||||
android:authorities="${applicationId}.provider"
|
||||
android:exported="false"
|
||||
android:grantUriPermissions="true">
|
||||
<meta-data
|
||||
android:name="android.support.FILE_PROVIDER_PATHS"
|
||||
android:resource="@xml/provider_paths" />
|
||||
</provider>
|
||||
</application>
|
||||
<!-- Required to query activities that can process text, see:
|
||||
https://developer.android.com/training/package-visibility and
|
||||
|
|
|
|||
|
|
@ -1,5 +0,0 @@
|
|||
package nexus.federated.nexus
|
||||
|
||||
import io.flutter.embedding.android.FlutterActivity
|
||||
|
||||
class MainActivity: FlutterActivity()
|
||||
|
|
@ -0,0 +1,40 @@
|
|||
package nexus.federated.nexus
|
||||
|
||||
import android.os.Build
|
||||
import android.os.Bundle
|
||||
import android.view.View
|
||||
import android.view.WindowInsets
|
||||
import android.view.WindowInsetsAnimation
|
||||
import io.flutter.embedding.android.FlutterActivity
|
||||
|
||||
// TODO: Revert this commit once https://github.com/flutter/flutter/issues/191156 is fixed
|
||||
class MainActivity: FlutterActivity() {
|
||||
override fun onCreate(savedInstanceState: Bundle?) {
|
||||
super.onCreate(savedInstanceState)
|
||||
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.R) return
|
||||
|
||||
window.decorView.setWindowInsetsAnimationCallback(
|
||||
object : WindowInsetsAnimation.Callback(DISPATCH_MODE_CONTINUE_ON_SUBTREE) {
|
||||
override fun onProgress(
|
||||
insets: WindowInsets,
|
||||
runningAnimations: List<WindowInsetsAnimation>,
|
||||
) = insets
|
||||
|
||||
override fun onEnd(animation: WindowInsetsAnimation) {
|
||||
if ((animation.typeMask and WindowInsets.Type.ime()) != 0) reapplyInsets()
|
||||
}
|
||||
},
|
||||
)
|
||||
}
|
||||
|
||||
override fun onWindowFocusChanged(hasFocus: Boolean) {
|
||||
super.onWindowFocusChanged(hasFocus)
|
||||
if (hasFocus && Build.VERSION.SDK_INT >= Build.VERSION_CODES.R) reapplyInsets()
|
||||
}
|
||||
|
||||
// Posted so it runs after Flutter has applied any insets it deferred.
|
||||
private fun reapplyInsets() {
|
||||
val view = findViewById<View>(FLUTTER_VIEW_ID) ?: return
|
||||
view.post { view.rootWindowInsets?.let(view::onApplyWindowInsets) }
|
||||
}
|
||||
}
|
||||
6
android/app/src/main/res/xml/provider_paths.xml
Normal file
6
android/app/src/main/res/xml/provider_paths.xml
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<paths xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<external-path
|
||||
name="external_files"
|
||||
path="." />
|
||||
</paths>
|
||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue