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

Rebase/element android 1.4.32 #713

Merged
merged 229 commits into from
Aug 26, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
229 commits
Select commit Hold shift + click to select a range
0dc80db
Bump dokka-gradle-plugin from 1.7.0 to 1.7.10
dependabot[bot] Jul 12, 2022
6ed36e8
Bump io.gitlab.arturbosch.detekt from 1.20.0 to 1.21.0
dependabot[bot] Jul 18, 2022
50b7f3e
Ad group `io.github.davidburstrom.contester` for detekt 1.21.0
bmarty Jul 19, 2022
b4f833c
Detekt: disable rule `InstanceOfCheckForException`
bmarty Jul 19, 2022
40f8d94
Detekt: Use require() instead of throwing an IllegalArgumentException…
bmarty Jul 19, 2022
62f2fe1
Detekt: This explicit usage of `it` as the lambda parameter name can …
bmarty Jul 19, 2022
2d76138
Detekt: disable rule `UseCheckOrError`
bmarty Jul 19, 2022
4dccff4
Improves formatting in AppStateHandler
ericdecanini Jul 7, 2022
e4c8c88
Refactors AppStateHandler into interface implementation pattern
ericdecanini Jul 8, 2022
fbdbfb6
Post cherry pick fix
ericdecanini Jul 8, 2022
49992f6
Adds test for existing space
ericdecanini Jul 21, 2022
f770ae0
Adds tests for persist space and backstack
ericdecanini Jul 21, 2022
9a649b6
Adds tests for selectedSpaceFlow and activeSpaceId
ericdecanini Jul 21, 2022
f0ae458
Changes AppStateHandler to SpaceStateHandler
ericdecanini Jul 21, 2022
1d77f99
Adds RoomSummaryFixture
ericdecanini Jul 21, 2022
d8fdaf0
Moves UiStateRepository stubbing to fake class
ericdecanini Jul 21, 2022
a909779
Merge remote-tracking branch 'origin/develop' into task/eric/space-sw…
ericdecanini Jul 21, 2022
8b220de
Adds changelog file
ericdecanini Jul 21, 2022
d8668f7
Rearranges imports
ericdecanini Jul 21, 2022
3df337f
Adds new layout toolbar
ericdecanini Jul 26, 2022
a503928
Adds feature flag functionality
ericdecanini Jul 26, 2022
5958559
Styles collapsed title text
ericdecanini Jul 26, 2022
f56c315
Dedicated notification builder and opening map on tap of notification
Jul 26, 2022
f3ad9e3
Update the notification when starting/stopping new live in room
Jul 26, 2022
fb82b1d
Adding changelog entry
Jul 26, 2022
7334d90
Adds options menu
ericdecanini Jul 26, 2022
7de82e0
Adds white status and navigation bars
ericdecanini Jul 27, 2022
9a981bb
Adds profile icon to toolbar
ericdecanini Jul 27, 2022
d3a1783
Adds invites to new home menu
ericdecanini Jul 27, 2022
3c8401b
Adds changelog file
ericdecanini Jul 27, 2022
e77688b
adding splash action tests
ouchadam Jul 27, 2022
87a0957
adding test around login with token
ouchadam Jul 27, 2022
a32a787
adding test around login with username and password
ouchadam Jul 27, 2022
c483151
adding tests around the state resetting
ouchadam Jul 27, 2022
4958b8a
Bump fragment from 1.5.0 to 1.5.1
dependabot[bot] Jul 27, 2022
5b9c7c3
Bump flipper from 0.154.0 to 0.156.0
dependabot[bot] Jul 27, 2022
a11d5eb
Replaces TODOs
ericdecanini Jul 28, 2022
e6addd1
Merge remote-tracking branch 'origin/develop' into task/eric/space-sw…
ericdecanini Jul 28, 2022
590f99a
Adds comments to SpaceStateHandler
ericdecanini Jul 28, 2022
bb9459f
adding test around sso url fetching
ouchadam Jul 28, 2022
d304624
removing extra blank lines
ouchadam Jul 28, 2022
b2e64e6
Fixing missing clear on TabLayoutMediator when view is destroyed
Jul 28, 2022
2b58c42
Adding changelog entry
Jul 28, 2022
2c5504f
Bump com.autonomousapps.dependency-analysis from 1.9.0 to 1.11.2
dependabot[bot] Jul 28, 2022
ca49cce
Merge branch 'release/v1.4.30' into develop
ouchadam Jul 29, 2022
67d4afa
updating build versions for next release cycle
ouchadam Jul 29, 2022
a52a250
We do not use TravisCI anymore.
bmarty Jul 27, 2022
56691f6
Setup Danger to Element Android project.
bmarty Jul 29, 2022
630a981
No need for ktlint comment, Danger will inline comment
bmarty Jul 27, 2022
a062093
Merge jobs that generate XML reports together
bmarty Jul 27, 2022
036521a
Add changelog
bmarty Jul 27, 2022
b77475a
Gradle daemon does not stop to get killed, try to split lint check in…
bmarty Jul 28, 2022
cc6dad3
Ignore PluralsCandidate, I do not know why it is reported by Danger, …
bmarty Jul 28, 2022
4d62e75
Get all the reports, in all the formats
bmarty Jul 28, 2022
66fa285
Call the correct command for knit
bmarty Jul 28, 2022
fb67499
Knit: do not check `node_modules` folder
bmarty Jul 28, 2022
3a5c139
Converting drawable to bitmap for map symbol to fix invisible text
Jul 29, 2022
79ea668
Adding changelog entry
Jul 29, 2022
4f5ad81
Fixes AppStateHandlers in code after merge
ericdecanini Jul 29, 2022
c7d5cec
Merge pull request #6644 from vector-im/feature/mna/notification-tap-lls
mnaturel Jul 29, 2022
c863b90
Merge pull request #6683 from vector-im/dependabot/gradle/com.autonom…
bmarty Jul 29, 2022
59f00cd
Merge pull request #6637 from vector-im/feature/bma/danger
bmarty Jul 29, 2022
e9aab63
Improve layout preview, item_group does not exist anymore.
bmarty Jul 28, 2022
07dc0d2
Rename layout for clarity
bmarty Jul 28, 2022
b161e5e
Add Kdoc on SpaceListFragment
bmarty Jul 28, 2022
3d72211
Avoid running this workflow twice on PR. #6690
bmarty Jul 29, 2022
619e5dd
Try to use a token from ElementBot, to let PR created from fork be ab…
bmarty Jul 29, 2022
c41f0dd
Do not request PR created by Dependabot to include a Sign-off.
bmarty Jul 29, 2022
d606958
Do not require a changelog file for PR created by Dependabot.
bmarty Jul 29, 2022
c20c3a7
Bump activity from 1.5.0 to 1.5.1
dependabot[bot] Jul 27, 2022
a83f714
Bump lifecycle from 2.5.0 to 2.5.1
dependabot[bot] Jul 27, 2022
fa8f110
Merge pull request #6667 from vector-im/feature/bma/group_cleanup_2
bmarty Jul 29, 2022
5e19838
Merge pull request #6691 from vector-im/feature/bma/validateGradleWra…
bmarty Jul 29, 2022
725ed00
Change some severities
bmarty Jul 29, 2022
ddaf112
Merge pull request #6598 from vector-im/task/eric/space-switching-uni…
ericdecanini Jul 29, 2022
302edb4
Merge pull request #6659 from vector-im/dependabot/gradle/flipper-0.1…
bmarty Jul 29, 2022
68cd7d4
Merge pull request #6524 from vector-im/dependabot/gradle/org.jetbrai…
bmarty Jul 29, 2022
91b0465
Translated using Weblate (Chinese (Simplified))
lcfork Aug 1, 2022
6671a10
Translated using Weblate (Chinese (Simplified))
Jul 31, 2022
21e88ef
Merge pull request #6657 from vector-im/dependabot/gradle/fragment-1.5.1
mnaturel Aug 1, 2022
3845e14
Fix cleartext leak in log
SpiritCroc Aug 1, 2022
fedbe04
creating a dedicated threadsafe Session instance initializer in order…
ouchadam Aug 1, 2022
410a7b5
reusing the suspend scope
ouchadam Aug 1, 2022
6b754f3
avoiding unneeded main context switch
ouchadam Aug 1, 2022
dbe5b35
adding changelog entry
ouchadam Aug 1, 2022
cf247ea
Merge pull request #6706 from SpiritCroc/leak
ouchadam Aug 1, 2022
9ea0f88
Fix cleartext leak in log
SpiritCroc Aug 1, 2022
3725921
using injectable dispatchers instead of direct usage
ouchadam Aug 1, 2022
9114630
replacing single context thread with semaphore
ouchadam Aug 1, 2022
e0349b2
updating version for hotfix release
ouchadam Aug 1, 2022
0c4c695
adding missing fullstops in to docs
ouchadam Aug 1, 2022
cf5745e
Merge pull request #6710 from vector-im/feature/adm/always-initialise…
ouchadam Aug 1, 2022
fde2aee
Merge branch 'hotfix/v1.4.31' of github.com:vector-im/element-android…
ouchadam Aug 1, 2022
e1c572e
generating 1.4.31 changelog
ouchadam Aug 1, 2022
dbb999d
Merge branch 'hotfix/v1.4.31'
ouchadam Aug 1, 2022
1411fdd
Merge branch 'hotfix/v1.4.31' into develop
ouchadam Aug 1, 2022
be696f5
Align naming of components for the live location feature
Jul 27, 2022
a8df1af
Adding changelog entry
Jul 27, 2022
c616229
Missing renaming of stylable file
Jul 27, 2022
8571fd0
Fix after rebase
Aug 1, 2022
004f40b
Setting 5 seconds for min period of update for location tracking
Jul 27, 2022
0944b2f
Adding changelog entry
Jul 27, 2022
49ad37a
Using Duration to have clearer syntax
Aug 2, 2022
74c9a71
Merge pull request #6648 from vector-im/feature/mna/align-naming-lls
mnaturel Aug 2, 2022
4f71741
Fixing leak on OnSymbolClickListener
Jul 27, 2022
9781656
Fixing leak on bottomSheetController callback
Jul 27, 2022
72e2951
Fixing missing cleanUp on RecyclerView
Jul 28, 2022
f44d8b0
Fixing missing call to SymbolManager.onDestroy()
Jul 28, 2022
2c10d9d
Fixing missing call to timer.cancel() when view is detached
Jul 28, 2022
e311d0e
Fixing missing cleanUp of the LocationSharingAndroidService
Jul 28, 2022
1ef809c
Adding changelog entry
Jul 28, 2022
c926b4c
Fix moving some components to dedicated package
Aug 2, 2022
5d30026
Merge pull request #6692 from vector-im/feature/bma/no_signoff_depend…
ouchadam Aug 2, 2022
7d120f9
reading the reviewers length from the github object as per the dsl
ouchadam Aug 2, 2022
ba5d6c9
replacing all danger mutable lets with const
ouchadam Aug 2, 2022
c99f67b
reading users field from the reviews object for calculating if review…
ouchadam Aug 2, 2022
3fe7a9d
Merge pull request #6588 from vector-im/dependabot/gradle/io.gitlab.a…
ouchadam Aug 2, 2022
1497650
Merge pull request #6715 from vector-im/feature/adm/danger-reviewers
ouchadam Aug 2, 2022
c848615
Disable 'Enable biometrics' option if there are not biometric authent…
jmartinesp Aug 2, 2022
274b1a1
moving analytics config to the config module, it's now up to forks to…
ouchadam Jun 30, 2022
87a8c78
moving the voice message limit to the config module
ouchadam Jun 30, 2022
e795e9d
porting the onboarding variant selection to the config
ouchadam Jun 30, 2022
f14aabc
ports the key sharing strategy to the config
ouchadam Jun 30, 2022
012485b
lifting the live location sharing build flag to the config along with…
ouchadam Jun 30, 2022
56afac2
creating a location sharing config for holding the map tiler key
ouchadam Jun 30, 2022
b6d052e
lifting voip setting to a voip config
ouchadam Jun 30, 2022
cc4aae0
replacing DEBUG build config flag with injectable property
ouchadam Jul 1, 2022
9fe3fc6
extracting the config models to their own files
ouchadam Jul 1, 2022
811b2e8
accessing the notification action ids via a dedicated class which bui…
ouchadam Jul 1, 2022
d42c27b
lifting the low privacy build config to the config
ouchadam Jul 1, 2022
df02f50
moving git versioning to the buildMeta abstraction
ouchadam Jul 1, 2022
18943e3
removing unused buildconfig option
ouchadam Jul 1, 2022
cceac66
moving build flavor information to the build meta
ouchadam Jul 8, 2022
c07296c
adding changelog entry
ouchadam Jul 11, 2022
3d207f9
removing unused imports and fixing missing full stop on docs
ouchadam Jul 11, 2022
fe1019f
using Config strict mode flag directly within the Application as the …
ouchadam Jul 11, 2022
cb59d82
extracting the notification action ids to their own file
ouchadam Jul 11, 2022
8b9d1bb
making use of the existing sdk int provider instead of supplying it v…
ouchadam Jul 11, 2022
9b1def3
updating variable casing as they're no longer const val or file level
ouchadam Jul 11, 2022
3c1e183
using low privacy log from the vector module for code within vector, …
ouchadam Jul 29, 2022
d1a63cc
removing unused import
ouchadam Jul 29, 2022
2ee52f2
fixing import ordering
ouchadam Aug 2, 2022
a53de92
Merge pull request #6688 from vector-im/fix/mna/missing-text-on-map-s…
mnaturel Aug 2, 2022
e2ed4b4
Merge pull request #6655 from vector-im/feature/eric/app-layout-toolbar
ericdecanini Aug 2, 2022
ac8597e
Merge pull request #6676 from vector-im/fix/mna/fix-memory-leaks-lls
mnaturel Aug 2, 2022
8aaf185
Merge pull request #6517 from vector-im/feature/adm/build-config
ouchadam Aug 2, 2022
4bff816
fixing auto merge compile error
ouchadam Aug 3, 2022
bfd9dcb
Merge pull request #6681 from vector-im/fix/mna/leak-tab-layout-mediator
mnaturel Aug 3, 2022
ee553d6
making use of gradle_opts environment var to attempt to limit the jvm…
ouchadam Aug 3, 2022
c6e263a
allowing parallel builds to occur now that the memory is constrained
ouchadam Aug 3, 2022
b625d6a
reducing CI workers to github VM limit
ouchadam Aug 3, 2022
b0f73b0
upping the jvm limit but keeping the kotlin daemon constrained
ouchadam Aug 4, 2022
825ba77
taking into account non ascii characters as invalid username error
ouchadam Aug 4, 2022
a4ea47e
catching username availabilty exceptions and handling as user facing …
ouchadam Aug 4, 2022
9a97e0b
adding changelog entry
ouchadam Aug 4, 2022
dd69b25
Merge pull request #6654 from vector-im/feature/mna/update-sending-pe…
mnaturel Aug 4, 2022
99de618
adding edit text ids so that the content can automatically be restore…
ouchadam Aug 4, 2022
f40cf13
fixing login/account creation errors showing when navigating to anoth…
ouchadam Aug 4, 2022
b6582c4
adding changelog entry
ouchadam Aug 4, 2022
8470ac9
removing unneeded --stacktrace flag, it's part of the CI_GRADLE_ARG_P…
ouchadam Aug 4, 2022
e26d87c
Merge pull request #6728 from vector-im/feature/adm/limited-ci-memory
ouchadam Aug 4, 2022
09a91c4
Make it easier to find developer sign-off instructions (#6739)
michaelkaye Aug 4, 2022
8b8a4f3
Fixing missing clear on audio tracker listeners
Jul 28, 2022
018772c
Adding changelog entry
Jul 28, 2022
81cba3d
Using ViewModel to handle clearing of audio controller
Jul 29, 2022
64c25f0
Calling directly the ViewModel clear method instead of using a view a…
Aug 1, 2022
8f91278
Creating custom view for map loading error
Jul 29, 2022
b83acf3
Adding error view in preview and sharing fragments
Jul 29, 2022
6572a1a
Fix missing icon in error view
Jul 29, 2022
87ca960
Keep the previous loading map error string for timeline
Jul 29, 2022
e0e06c6
Handling map loading error in sharing and preview fragment
Aug 1, 2022
6972622
Handling map loading error in timeline
Aug 1, 2022
a30076a
Creating location.preview package
Aug 1, 2022
008e07d
Handling map loading error in live location maximized map
Aug 1, 2022
6590cf5
adding changelog entry
Aug 1, 2022
ec5f874
Fixing code formatting issues
Aug 1, 2022
72377c9
Fixing after rebase
Aug 3, 2022
2b8632e
Adding missing trailing comma
Aug 3, 2022
65c6e57
Moving setup of map in onViewCreated + moving reference assignment of…
Aug 3, 2022
30a8f22
Bump libphonenumber from 8.12.52 to 8.12.53
dependabot[bot] Aug 4, 2022
619cb29
Merge pull request #6679 from vector-im/fix/mna/audio-controller-leak
mnaturel Aug 5, 2022
f0bd5dc
Merge pull request #6744 from vector-im/dependabot/gradle/com.googlec…
ouchadam Aug 5, 2022
2dc92ca
Merge pull request #6712 from vector-im/feature/mna/map-loading-error
mnaturel Aug 5, 2022
b375dd1
removing unused line
ouchadam Aug 5, 2022
5864ce4
adding rule to force a new session to be started for instrumentation …
ouchadam Aug 5, 2022
03afd29
NewHomeDetailFragment now shows correct list fragment (#6740)
fedrunov Aug 5, 2022
2683e92
resetting the analytics datastore via reflection
ouchadam Aug 5, 2022
81897a1
Merge pull request #6741 from vector-im/feature/adm/focus-errors
ouchadam Aug 5, 2022
20b3dbc
documenting the rule and reflection helper
ouchadam Aug 5, 2022
c2fbb74
Translated using Weblate (Arabic)
Aug 5, 2022
f33e2fd
Translated using Weblate (Catalan)
Atalonica Aug 2, 2022
a56d8a2
Translated using Weblate (Czech)
waclaw66 Jul 29, 2022
4af4f3f
Translated using Weblate (German)
Aug 5, 2022
7b96597
Translated using Weblate (Estonian)
Jul 30, 2022
dbbdc17
Translated using Weblate (Persian)
danialbehzadi Jul 28, 2022
4a3b6ba
Translated using Weblate (French)
Glandos Jul 29, 2022
8cbdd6e
Translated using Weblate (Hungarian)
notramo Aug 3, 2022
804880c
Translated using Weblate (Italian)
Aug 1, 2022
721c4c0
Translated using Weblate (Dutch)
johansmitsnl Aug 4, 2022
a41ad66
Translated using Weblate (Polish)
rom4nik Jul 29, 2022
ee1f294
Translated using Weblate (Portuguese (Brazil))
Aug 4, 2022
05816d0
Translated using Weblate (Russian)
Aug 5, 2022
2aac0c9
Translated using Weblate (Slovak)
dodog Jul 28, 2022
fde0d81
Translated using Weblate (Ukrainian)
IhorHordiichuk Aug 2, 2022
e15e941
Translated using Weblate (Chinese (Simplified))
Aug 3, 2022
ec9199c
Translated using Weblate (Chinese (Traditional))
Aug 3, 2022
77ae291
Translated using Weblate (Chinese (Traditional))
s8321414 Jul 29, 2022
ac047af
Translated using Weblate (Vietnamese)
Aug 4, 2022
dd496dc
Merge pull request #6748 from vector-im/feature/adm/flaky-verificatio…
ouchadam Aug 8, 2022
7e7b98a
Merge pull request #6668 from vector-im/feature/adm/onboarding-vm-tests
ouchadam Aug 8, 2022
b2d1915
Translated using Weblate (Russian)
Aug 7, 2022
58d47df
Merge pull request #6736 from vector-im/feature/adm/non-ascii-username
ouchadam Aug 9, 2022
6e1e31b
Avoid crashes from unknown exceptions on lockscreen key migration.
jmartinesp Aug 9, 2022
2f4725c
Prevent crash while validating biometric key.
jmartinesp Aug 8, 2022
dfc8526
Refactor lockscreen implementation.
jmartinesp Aug 9, 2022
cc59b9e
Address review comments.
jmartinesp Aug 9, 2022
9888e15
Improve logic to trigger LockScreenViewEvents
jmartinesp Aug 9, 2022
6045eac
recents carousel for new home screen layout (#6707)
fedrunov Aug 9, 2022
fe61fa8
Merge pull request #6784 from vector-im/fix/jorgem/lockscreen-device-…
ouchadam Aug 9, 2022
53e396d
Merge branch 'origin/develop' into Weblate.
weblate Aug 9, 2022
ac6b0a9
Merge pull request #6790 from RiotTranslateBot/weblate-element-androi…
ouchadam Aug 9, 2022
e81da5d
generating 1.4.32 changelog
ouchadam Aug 10, 2022
ce28d7f
Merge branch 'release/v1.4.32'
ouchadam Aug 10, 2022
29414f0
Merge tag 'v1.4.32' into rebase/element-android-1.4.32
Aug 23, 2022
d67867a
Remove useless feature flags
Aug 23, 2022
c766db9
[CI] Run tests on withoutpinning variant
Aug 24, 2022
f3d3332
Do not use tchap login flow for tests
Aug 24, 2022
bb1e920
Fix crypto tests by setting a different crypto config in the MatrixCo…
Aug 25, 2022
edf775d
Ignore test related to secure backup
Aug 25, 2022
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
10 changes: 4 additions & 6 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,8 @@ on:

# Enrich gradle.properties for CI/CD
env:
CI_GRADLE_ARG_PROPERTIES: >
-Porg.gradle.jvmargs=-Xmx4g
-Porg.gradle.parallel=false
--no-daemon
GRADLE_OPTS: -Dorg.gradle.jvmargs="-Xmx3072m -Dfile.encoding=UTF-8 -XX:+HeapDumpOnOutOfMemoryError" -Dkotlin.daemon.jvm.options="-Xmx2560m" -Dkotlin.incremental=false
CI_GRADLE_ARG_PROPERTIES: --stacktrace -PpreDexEnable=false --max-workers 2 --no-daemon

jobs:
debug:
Expand All @@ -37,7 +35,7 @@ jobs:
restore-keys: |
${{ runner.os }}-gradle-
- name: Assemble ${{ matrix.target }} debug apk
run: ./gradlew assemble${{ matrix.target }}Debug $CI_GRADLE_ARG_PROPERTIES --stacktrace
run: ./gradlew assemble${{ matrix.target }}Debug $CI_GRADLE_ARG_PROPERTIES
- name: Upload ${{ matrix.target }} debug APKs
uses: actions/upload-artifact@v3
with:
Expand Down Expand Up @@ -69,7 +67,7 @@ jobs:
restore-keys: |
${{ runner.os }}-gradle-
- name: Assemble ${{ matrix.target }} unsigned apk
run: ./gradlew clean assemble${{ matrix.target }}Release $CI_GRADLE_ARG_PROPERTIES --stacktrace
run: ./gradlew clean assemble${{ matrix.target }}Release $CI_GRADLE_ARG_PROPERTIES
- name: Upload ${{ matrix.target }} unsigned APKs
uses: actions/upload-artifact@v3
with:
Expand Down
18 changes: 18 additions & 0 deletions .github/workflows/danger.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Danger CI

on: [pull_request]

jobs:
build:
runs-on: ubuntu-latest
name: Danger
steps:
- uses: actions/checkout@v3
- run: |
npm install --save-dev @babel/plugin-transform-flow-strip-types
- name: Danger
uses: danger/[email protected]
with:
args: "--dangerfile tools/danger/dangerfile.js"
env:
DANGER_GITHUB_API_TOKEN: ${{ secrets.DANGER_GITHUB_API_TOKEN }}
5 changes: 4 additions & 1 deletion .github/workflows/gradle-wrapper-validation.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
name: "Validate Gradle Wrapper"
on: [push, pull_request]
on:
pull_request: { }
push:
branches: [ main, develop ]

jobs:
validation:
Expand Down
8 changes: 3 additions & 5 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,8 @@ on:
- cron: "0 4 * * *"

env:
CI_GRADLE_ARG_PROPERTIES: >
-Porg.gradle.jvmargs=-Xmx4g
-Porg.gradle.parallel=false
--no-daemon
GRADLE_OPTS: -Dorg.gradle.jvmargs="-Xmx3072m -Dfile.encoding=UTF-8 -XX:+HeapDumpOnOutOfMemoryError" -Dkotlin.daemon.jvm.options="-Xmx2560m" -Dkotlin.incremental=false
CI_GRADLE_ARG_PROPERTIES: --stacktrace -PpreDexEnable=false --max-workers 2 --no-daemon

jobs:
nightly:
Expand Down Expand Up @@ -42,7 +40,7 @@ jobs:
yes n | towncrier build --version nightly
- name: Build and upload Gplay Nightly APK
run: |
./gradlew assembleGplayNightly appDistributionUploadGplayNightly $CI_GRADLE_ARG_PROPERTIES --stacktrace
./gradlew assembleGplayNightly appDistributionUploadGplayNightly $CI_GRADLE_ARG_PROPERTIES
env:
ELEMENT_ANDROID_NIGHTLY_KEYID: ${{ secrets.ELEMENT_ANDROID_NIGHTLY_KEYID }}
ELEMENT_ANDROID_NIGHTLY_KEYPASSWORD: ${{ secrets.ELEMENT_ANDROID_NIGHTLY_KEYPASSWORD }}
Expand Down
6 changes: 2 additions & 4 deletions .github/workflows/post-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,8 @@ on:

# Enrich gradle.properties for CI/CD
env:
CI_GRADLE_ARG_PROPERTIES: >
-Porg.gradle.jvmargs=-Xmx4g
-Porg.gradle.parallel=false
--no-daemon
GRADLE_OPTS: -Dorg.gradle.jvmargs="-Xmx3072m -Dfile.encoding=UTF-8 -XX:+HeapDumpOnOutOfMemoryError" -Dkotlin.daemon.jvm.options="-Xmx2560m" -Dkotlin.incremental=false
CI_GRADLE_ARG_PROPERTIES: --stacktrace -PpreDexEnable=false --max-workers 2 --no-daemon

jobs:

Expand Down
192 changes: 28 additions & 164 deletions .github/workflows/quality.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

name: Code Quality Checks

on:
Expand All @@ -8,10 +7,8 @@ on:

# Enrich gradle.properties for CI/CD
env:
CI_GRADLE_ARG_PROPERTIES: >
-Porg.gradle.jvmargs=-Xmx4g
-Porg.gradle.parallel=false
--no-daemon
GRADLE_OPTS: -Dorg.gradle.jvmargs="-Xmx3072m -Dfile.encoding=UTF-8 -XX:+HeapDumpOnOutOfMemoryError" -Dkotlin.daemon.jvm.options="-Xmx2560m" -Dkotlin.incremental=false
CI_GRADLE_ARG_PROPERTIES: --stacktrace -PpreDexEnable=false --max-workers 2 --no-daemon

jobs:
check:
Expand All @@ -30,79 +27,50 @@ jobs:
- uses: actions/checkout@v3
- name: Run knit
run: |
./gradlew knit
./gradlew knitCheck

# ktlint for all the modules
ktlint:
name: Kotlin Linter
# Check the project: ktlint, detekt, lint
lint:
name: Android Linter
runs-on: ubuntu-latest
# Allow all jobs on main and develop. Just one per PR.
concurrency:
group: ${{ github.ref == 'refs/heads/main' && format('ktlint-main-{0}', github.sha) || github.ref == 'refs/heads/develop' && format('ktlint-develop-{0}', github.sha) || format('ktlint-{0}', github.ref) }}
group: ${{ github.ref == 'refs/heads/main' && format('lint-main-{0}', github.sha) || github.ref == 'refs/heads/develop' && format('lint-develop-{0}', github.sha) || format('lint-{0}', github.ref) }}
cancel-in-progress: true
steps:
- uses: actions/checkout@v3
- name: Run ktlint
run: |
./gradlew ktlintCheck --continue
- name: Run detekt
if: always()
run: |
./gradlew detekt $CI_GRADLE_ARG_PROPERTIES
- name: Run lint
# Not always, if ktlint or detekt fail, avoid running the long lint check.
run: |
./gradlew lintGplayRelease $CI_GRADLE_ARG_PROPERTIES
./gradlew lintFdroidRelease $CI_GRADLE_ARG_PROPERTIES
- name: Upload reports
if: always()
uses: actions/upload-artifact@v3
with:
name: ktlinting-report
name: linting-report
path: |
*/build/reports/ktlint/ktlint*/ktlint*.txt
- name: Handle Results
*/build/reports/**/*.*
- name: Prepare Danger
if: always()
id: ktlint-results
run: |
results="$(cat */*/build/reports/ktlint/ktlint*/ktlint*.txt */build/reports/ktlint/ktlint*/ktlint*.txt | sed -r "s/\x1B\[([0-9]{1,3}(;[0-9]{1,2})?)?[mGK]//g")"
if [ -z "$results" ]; then
echo "::set-output name=add_comment::false"
else
body="👎\`Failed${results}\`"
body="${body//'%'/'%25'}"
body="${body//$'\n'/'%0A'}"
body="${body//$'\r'/'%0D'}"
body="$( echo $body | sed 's/\/home\/runner\/work\/tchap-android\/tchap-android\//\`<br\/>\`/g')"
body="$( echo $body | sed 's/\/src\/main\/java\// 🔸 /g')"
body="$( echo $body | sed 's/im\/vector\/app\///g')"
body="$( echo $body | sed 's/im\/vector\/lib\/attachmentviewer\///g')"
body="$( echo $body | sed 's/im\/vector\/lib\/multipicker\///g')"
body="$( echo $body | sed 's/im\/vector\/lib\///g')"
body="$( echo $body | sed 's/org\/matrix\/android\/sdk\///g')"
body="$( echo $body | sed 's/\/src\/androidTest\/java\// 🔸 /g')"
echo "::set-output name=add_comment::true"
echo "::set-output name=body::$body"
fi
- name: Find Comment
if: always() && github.event_name == 'pull_request'
uses: peter-evans/find-comment@v2
id: fc
with:
issue-number: ${{ github.event.pull_request.number }}
comment-author: 'github-actions[bot]'
body-includes: Ktlint Results
- name: Add comment if needed
if: always() && github.event_name == 'pull_request' && steps.ktlint-results.outputs.add_comment == 'true'
uses: peter-evans/create-or-update-comment@v2
with:
comment-id: ${{ steps.fc.outputs.comment-id }}
issue-number: ${{ github.event.pull_request.number }}
body: |
### Ktlint Results
${{ steps.ktlint-results.outputs.body }}
edit-mode: replace
- name: Delete comment if needed
if: always() && github.event_name == 'pull_request' && steps.fc.outputs.comment-id != '' && steps.ktlint-results.outputs.add_comment == 'false'
uses: actions/github-script@v3
npm install --save-dev @babel/core
npm install --save-dev @babel/plugin-transform-flow-strip-types
yarn add danger-plugin-lint-report --dev
- name: Danger lint
if: always()
uses: danger/[email protected]
with:
script: |
github.issues.deleteComment({
owner: context.repo.owner,
repo: context.repo.repo,
comment_id: ${{ steps.fc.outputs.comment-id }}
})
args: "--dangerfile tools/danger/dangerfile-lint.js"
env:
DANGER_GITHUB_API_TOKEN: ${{ secrets.DANGER_GITHUB_API_TOKEN }}

# Gradle dependency analysis using https://github.com/autonomousapps/dependency-analysis-android-gradle-plugin
dependency-analysis:
Expand All @@ -122,107 +90,3 @@ jobs:
with:
name: dependency-analysis
path: build/reports/dependency-check-report.html

# Lint for main module
android-lint:
name: Android Linter
runs-on: ubuntu-latest
# Allow all jobs on main and develop. Just one per PR.
concurrency:
group: ${{ github.ref == 'refs/heads/main' && format('android-lint-main-{0}', github.sha) || github.ref == 'refs/heads/develop' && format('android-lint-develop-{0}', github.sha) || format('android-lint-{0}', github.ref) }}
cancel-in-progress: true
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: Lint analysis
run: ./gradlew clean :vector:lint --stacktrace $CI_GRADLE_ARG_PROPERTIES
- name: Upload reports
if: always()
uses: actions/upload-artifact@v3
with:
name: lint-report
path: |
vector/build/reports/*.*

# Lint for Gplay and Fdroid release APK
apk-lint:
name: Lint APK (${{ matrix.target }})
runs-on: ubuntu-latest
if: github.ref != 'refs/heads/main'
strategy:
fail-fast: false
matrix:
target: [ GplayBtchapWithoutvoipWithpinning, FdroidBtchapWithoutvoipWithoutpinning ]
# Allow all jobs on develop. Just one per PR.
concurrency:
group: ${{ github.ref == 'refs/heads/develop' && format('apk-lint-develop-{0}-{1}', matrix.target, github.sha) || format('apk-lint-{0}-{1}', matrix.target, github.ref) }}
cancel-in-progress: true
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: Lint ${{ matrix.target }} release
run: ./gradlew clean lint${{ matrix.target }}Release --stacktrace $CI_GRADLE_ARG_PROPERTIES
- name: Upload ${{ matrix.target }} linting report
if: always()
uses: actions/upload-artifact@v3
with:
name: release-lint-report-${{ matrix.target }}
path: |
vector/build/reports/*.*

detekt:
name: Detekt Analysis
runs-on: ubuntu-latest
# Allow all jobs on main and develop. Just one per PR.
concurrency:
group: ${{ github.ref == 'refs/heads/main' && format('detekt-main-{0}', github.sha) || github.ref == 'refs/heads/develop' && format('detekt-develop-{0}', github.sha) || format('detekt-{0}', github.ref) }}
cancel-in-progress: true
steps:
- uses: actions/checkout@v3
- name: Run detekt
run: |
./gradlew detekt $CI_GRADLE_ARG_PROPERTIES
- name: Upload reports
if: always()
uses: actions/upload-artifact@v3
with:
name: detekt-report
path: |
*/build/reports/detekt/detekt.html

# towncrier:
# name: Towncrier check
# runs-on: ubuntu-latest
# if: github.event_name == 'pull_request' && github.head_ref == 'develop'
# steps:
# - uses: actions/checkout@v3
# - name: Set up Python 3.8
# uses: actions/setup-python@v4
# with:
# python-version: 3.8
# - name: Install towncrier
# run: |
# python3 -m pip install towncrier
# - name: Run towncrier
# # Fetch the pull request' base branch so towncrier will be able to
# # compare the current branch with the base branch.
# # Source: https://github.com/actions/checkout/#fetch-all-branches.
# run: |
# git fetch --no-tags origin +refs/heads/${BASE_BRANCH}:refs/remotes/origin/${BASE_BRANCH}
# towncrier check --compare-with origin/${BASE_BRANCH}
# env:
# BASE_BRANCH: ${{ github.base_ref }}
2 changes: 1 addition & 1 deletion .github/workflows/sanity_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ jobs:
touch emulator.log
chmod 777 emulator.log
adb logcat >> emulator.log &
./gradlew $CI_GRADLE_ARG_PROPERTIES -PallWarningsAsErrors=false connectedGplayBtchapWithoutvoipWithpinningDebugAndroidTest -Pandroid.testInstrumentationRunnerArguments.class=im.vector.app.ui.UiAllScreensSanityTest || adb pull storage/emulated/0/Pictures/failure_screenshots && exit 1
./gradlew $CI_GRADLE_ARG_PROPERTIES -PallWarningsAsErrors=false connectedGplayBtchapWithoutvoipWithoutpinningDebugAndroidTest -Pandroid.testInstrumentationRunnerArguments.class=im.vector.app.ui.UiAllScreensSanityTest || adb pull storage/emulated/0/Pictures/failure_screenshots && exit 1
- name: Upload Test Report Log
uses: actions/upload-artifact@v2
if: always()
Expand Down
34 changes: 16 additions & 18 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,8 @@ on:

# Enrich gradle.properties for CI/CD
env:
CI_GRADLE_ARG_PROPERTIES: >
-Porg.gradle.jvmargs=-Xmx4g
-Porg.gradle.parallel=false
--no-daemon
GRADLE_OPTS: -Dorg.gradle.jvmargs="-Xmx3072m -Dfile.encoding=UTF-8 -XX:+HeapDumpOnOutOfMemoryError" -Dkotlin.daemon.jvm.options="-Xmx2560m" -Dkotlin.incremental=false
CI_GRADLE_ARG_PROPERTIES: --stacktrace -PpreDexEnable=false --max-workers 2 --no-daemon

jobs:
tests:
Expand Down Expand Up @@ -51,9 +49,9 @@ jobs:
disable-animations: true
emulator-build: 7425822
script: |
./gradlew unitTestsWithCoverage --stacktrace $CI_GRADLE_ARG_PROPERTIES
./gradlew instrumentationTestsWithCoverage --stacktrace $CI_GRADLE_ARG_PROPERTIES
./gradlew generateCoverageReport --stacktrace $CI_GRADLE_ARG_PROPERTIES
./gradlew unitTestsWithCoverage $CI_GRADLE_ARG_PROPERTIES
./gradlew instrumentationTestsWithCoverage $CI_GRADLE_ARG_PROPERTIES
./gradlew generateCoverageReport $CI_GRADLE_ARG_PROPERTIES
# NB: continue-on-error marks steps.tests.conclusion = 'success' but leaves stes.tests.outcome = 'failure'
- name: Run all the codecoverage tests at once (retry if emulator failed)
uses: reactivecircus/android-emulator-runner@v2
Expand All @@ -67,16 +65,16 @@ jobs:
disable-animations: true
emulator-build: 7425822
script: |
./gradlew unitTestsWithCoverage --stacktrace $CI_GRADLE_ARG_PROPERTIES
./gradlew instrumentationTestsWithCoverage --stacktrace $CI_GRADLE_ARG_PROPERTIES
./gradlew generateCoverageReport --stacktrace $CI_GRADLE_ARG_PROPERTIES
# Tchap: Skip for forks
# - run: ./gradlew sonarqube $CI_GRADLE_ARG_PROPERTIES
# if: always() # we may have failed a previous step and retried, that's OK
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
# ORG_GRADLE_PROJECT_SONAR_LOGIN: ${{ secrets.SONAR_TOKEN }}
./gradlew unitTestsWithCoverage $CI_GRADLE_ARG_PROPERTIES
./gradlew instrumentationTestsWithCoverage $CI_GRADLE_ARG_PROPERTIES
./gradlew generateCoverageReport $CI_GRADLE_ARG_PROPERTIES
- run: ./gradlew sonarqube $CI_GRADLE_ARG_PROPERTIES
# Tchap: Skip in forks
if: github.repository == 'vector-im/element-android' && always() # we may have failed a previous step and retried, that's OK
env:
GITHUB_TOKEN: ${{ secrets.SONARQUBE_GITHUB_API_TOKEN }} # Needed to get PR information, if any
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
ORG_GRADLE_PROJECT_SONAR_LOGIN: ${{ secrets.SONAR_TOKEN }}

- name: Format unit test results
if: always()
Expand Down Expand Up @@ -115,4 +113,4 @@ jobs:
# restore-keys: |
# ${{ runner.os }}-gradle-
# - name: Build Android Tests
# run: ./gradlew clean assembleAndroidTest $CI_GRADLE_ARG_PROPERTIES --stacktrace
# run: ./gradlew clean assembleAndroidTest $CI_GRADLE_ARG_PROPERTIES
Loading