This repository was archived by the owner on Jan 16, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 6 files changed +15
-28
lines changed
src/main/java/com/github/jing332/alistandroid/ui Expand file tree Collapse file tree 6 files changed +15
-28
lines changed Original file line number Diff line number Diff line change 11name : Release
22
33on :
4+ push :
5+ branches :
6+ - " master"
7+ paths :
8+ - " CHANGELOG.md"
49 workflow_dispatch :
510
611jobs :
Original file line number Diff line number Diff line change 1- [ 自动同步AList] v3.30.0
1+ 修复:版本为null
2+ 新增:内置网页
Original file line number Diff line number Diff line change @@ -7,11 +7,13 @@ plugins {
77 id(" com.mikepenz.aboutlibraries.plugin" )
88}
99
10- Properties pro = new Properties ()
10+ def pro = new Properties ()
1111InputStream input = rootProject. file(" local.properties" ). newDataInputStream()
1212pro. load(input)
1313input. close()
1414
15+ def alistVersion = rootProject. file(" alist_version" ). newReader(). readLine()
16+
1517static def releaseTime () {
1618 return new Date (). format(" yy.MMddHH" , TimeZone . getTimeZone(" GMT+8" ))
1719}
@@ -34,8 +36,7 @@ android {
3436 arg(" room.expandProjection" , " true" )
3537 }
3638
37- buildConfigField " String" , " ALIST_VERSION" , " \" " + pro[" ALIST_VERSION" ] + " \" "
38- buildConfigField " String" , " ALIST_COMMIT_SHA" , " \" " + pro[" ALIST_COMMIT_SHA" ] + " \" "
39+ buildConfigField " String" , " ALIST_VERSION" , " \" " + alistVersion + " \" "
3940
4041 testInstrumentationRunner " androidx.test.runner.AndroidJUnitRunner"
4142 }
Original file line number Diff line number Diff line change @@ -40,8 +40,6 @@ class MainActivity : BaseComposeActivity() {
4040 super .onCreate(savedInstanceState)
4141
4242 lifecycleScope.launch {
43- if (AppConfig .isFirstRun)
44- killBattery()
4543 ShortCuts .buildShortCuts(this @MainActivity)
4644 }
4745 }
Original file line number Diff line number Diff line change @@ -129,18 +129,9 @@ fun AListScreen() {
129129 topBar = {
130130 TopAppBar (
131131 title = {
132- val miniSha = remember {
133- try {
134- BuildConfig .ALIST_COMMIT_SHA .slice(0 .. 6 )
135- } catch (_: Exception ) {
136- " "
137- }
138- }
139132 Row {
140133 Text (stringResource(R .string.app_name))
141- Text (
142- " - " + miniSha.ifEmpty { BuildConfig .ALIST_VERSION }
143- )
134+ Text (" - " + BuildConfig .ALIST_VERSION )
144135 }
145136 },
146137 actions = {
Original file line number Diff line number Diff line change @@ -58,17 +58,10 @@ fun AboutDialog(onDismissRequest: () -> Unit) {
5858 }
5959
6060 Column {
61- val miniSha = remember {
62- try {
63- BuildConfig .ALIST_COMMIT_SHA .slice(0 .. 6 )
64- } catch (_: Exception ) {
65- " "
66- }
67- }
6861 SelectionContainer {
6962 Column {
7063 Text (" APP - ${BuildConfig .VERSION_NAME } (${BuildConfig .VERSION_CODE } )" )
71- Text (" AList - ${miniSha.ifBlank { BuildConfig .ALIST_VERSION } } " )
64+ Text (" AList - ${BuildConfig .ALIST_VERSION } " )
7265 }
7366 }
7467 HorizontalDivider (Modifier .padding(vertical = 8 .dp))
@@ -85,15 +78,13 @@ fun AboutDialog(onDismissRequest: () -> Unit) {
8578 )
8679 Spacer (modifier = Modifier .height(4 .dp))
8780 Text (
88- " Github - AList (${miniSha.ifBlank { " Release" }} )" ,
81+ " Github - AList (Release)" ,
8982 color = MaterialTheme .colorScheme.primary,
9083 fontWeight = FontWeight .Bold ,
9184 modifier = Modifier
9285 .clickable {
9386 openUrl(
94- if (BuildConfig .ALIST_COMMIT_SHA .isEmpty())
95- " https://github.com/alist-org/alist/releases/tag/${BuildConfig .ALIST_VERSION } "
96- else " https://github.com/alist-org/alist/tree/${BuildConfig .ALIST_COMMIT_SHA } "
87+ " https://github.com/alist-org/alist/releases/tag/${BuildConfig .ALIST_VERSION } "
9788 )
9889 }
9990 .padding(vertical = 8 .dp)
You can’t perform that action at this time.
0 commit comments