Skip to content

Commit b566a4b

Browse files
author
Simon Schubert
committed
Release
1 parent f245705 commit b566a4b

13 files changed

Lines changed: 22 additions & 24 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
![Icon](https://raw.githubusercontent.com/SimonSchubert/LinuxCommandLibrary/master/art/web_hi_res_144.png)
44

5-
The app currently has **6056** manual pages, **22+** basic categories and a bunch of general terminal tips. It works 100% offline, doesn't need an internet connection and has no tracking software.
5+
The app currently has **6488** manual pages, **22+** basic categories and a bunch of general terminal tips. It works 100% offline, doesn't need an internet connection and has no tracking software.
66

77
[![Play Store](https://raw.githubusercontent.com/SimonSchubert/LinuxCommandBibliotheca/master/art/play_store_badge.png)](https://play.google.com/store/apps/details?id=com.inspiredandroid.linuxcommandbibliotheca)
88
[![F-Droid](https://raw.githubusercontent.com/SimonSchubert/LinuxCommandBibliotheca/master/art/fdroid_badge.png)](https://f-droid.org/en/packages/com.inspiredandroid.linuxcommandbibliotheca/)

android/build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ android {
3939
applicationId = "com.inspiredandroid.linuxcommandbibliotheca"
4040
minSdk = 24
4141
targetSdk = 35
42-
versionCode = 93
42+
versionCode = 94
4343
versionName = project.version.toString()
4444
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
4545
}

android/src/main/java/com/inspiredandroid/linuxcommandbibliotheca/LinuxApplication.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ import com.inspiredandroid.linuxcommandbibliotheca.ui.screens.commandlist.Comman
88
import com.inspiredandroid.linuxcommandbibliotheca.ui.screens.tips.TipsViewModel
99
import org.koin.android.ext.koin.androidContext
1010
import org.koin.android.ext.koin.androidLogger
11-
import org.koin.androidx.viewmodel.dsl.viewModel
1211
import org.koin.core.context.GlobalContext.startKoin
12+
import org.koin.core.module.dsl.*
1313
import org.koin.dsl.module
1414

1515
class LinuxApplication : Application() {

android/src/main/java/com/inspiredandroid/linuxcommandbibliotheca/PreferenceUtil.kt

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
package com.inspiredandroid.linuxcommandbibliotheca
22

33
import android.content.Context
4+
import androidx.core.content.edit
45
import androidx.preference.PreferenceManager
56

67
class PreferenceUtil(private val context: Context) {
@@ -16,7 +17,7 @@ class PreferenceUtil(private val context: Context) {
1617
private fun saveBookmarkIds() {
1718
val bookmarksChain = bookmarksIds.joinToString(separator = ",")
1819
val prefs = PreferenceManager.getDefaultSharedPreferences(context)
19-
prefs.edit().putString(KEY_BOOKMARKS, bookmarksChain).apply()
20+
prefs.edit { putString(KEY_BOOKMARKS, bookmarksChain) }
2021
}
2122

2223
fun addBookmark(id: Long) {
@@ -39,12 +40,12 @@ class PreferenceUtil(private val context: Context) {
3940

4041
fun updateDatabaseVersion(context: Context) {
4142
val prefs = PreferenceManager.getDefaultSharedPreferences(context)
42-
prefs.edit().putInt(KEY_DATABASE_VERSION, CURRENT_DATABASE_VERSION).apply()
43+
prefs.edit { putInt(KEY_DATABASE_VERSION, CURRENT_DATABASE_VERSION) }
4344
}
4445

4546
companion object {
4647
const val KEY_BOOKMARKS = "KEY_BOOKMARKS"
4748
const val KEY_DATABASE_VERSION = "DATABASE_VERSION"
48-
const val CURRENT_DATABASE_VERSION = 8
49+
const val CURRENT_DATABASE_VERSION = 9
4950
}
5051
}

android/src/main/java/com/inspiredandroid/linuxcommandbibliotheca/ui/screens/basicgroups/BasicGroupsScreen.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ fun BasicGroupsScreen(
5252
}
5353

5454
@Composable
55-
fun BasicGroupColumn(
55+
private fun BasicGroupColumn(
5656
viewModel: BasicGroupsViewModel,
5757
basicGroup: BasicGroup,
5858
onNavigate: (String) -> Unit = {},

android/src/main/java/com/inspiredandroid/linuxcommandbibliotheca/ui/screens/commanddetail/CommandDetailScreen.kt

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -58,10 +58,10 @@ fun CommandDetailScreen(
5858
}
5959

6060
@Composable
61-
fun CommandSectionColumn(
61+
private fun CommandSectionColumn(
6262
viewModel: CommandDetailViewModel,
6363
section: CommandSection,
64-
onNavigate: (String) -> Unit = {},
64+
onNavigate: (String) -> Unit,
6565
) {
6666
ListItem(
6767
text = {
@@ -81,9 +81,10 @@ fun CommandSectionColumn(
8181
Column(
8282
modifier = Modifier.padding(start = 16.dp, end = 16.dp),
8383
) {
84+
println(section.content)
8485
val tldrParts = section.content.split("<b>")
8586
tldrParts.forEachIndexed { index, s ->
86-
val split = s.split("</b><br>")
87+
val split = s.split("</b>")
8788
if (split.size > 1) {
8889
Text(
8990
text = split[0],
@@ -101,14 +102,14 @@ fun CommandSectionColumn(
101102
}
102103
}
103104
} else {
104-
val color = MaterialTheme.colors.onSurface
105+
val color = MaterialTheme.colors.onSurface.toArgb()
105106
ListItem(text = {
106107
AndroidView(factory = { context ->
107108
TextView(context).apply {
108109
val content =
109110
HtmlCompat.fromHtml(section.content, HtmlCompat.FROM_HTML_MODE_LEGACY)
110111
text = content.dropLastWhile { it.isWhitespace() }
111-
setTextColor(color.toArgb())
112+
setTextColor(color)
112113
}
113114
})
114115
})

assets/database.db

-18.6 MB
Binary file not shown.

build.gradle.kts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ buildscript {
1919
}
2020
}
2121

22-
group = "org.example"
23-
version = "3.2.7"
22+
group = "com.inspiredandroid"
23+
version = "3.3.0"
2424

2525
allprojects {
2626
repositories {
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
version=3.2.7
1+
version=3.3.0

desktop/src/main/kotlin/com/linuxcommandlibrary/desktop/WebsiteBuilder.kt

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -87,11 +87,6 @@ fun main() {
8787
websiteBuilder.createCommandsHtmlFile(folder)
8888

8989
websiteBuilder.createBasicsHtmlFile(folder)
90-
91-
minifier.minifyScriptsAndSheets(true)
92-
93-
return
94-
9590
websiteBuilder.createBasicHtmlFiles(File(folder, "basic"))
9691

9792
websiteBuilder.createTipsHtmlFile(folder)
@@ -104,7 +99,6 @@ fun main() {
10499
minifier.minifyScriptsAndSheets(true)
105100
}
106101

107-
108102
class WebsiteBuilder {
109103

110104
private val cacheVersion = 11
@@ -247,7 +241,7 @@ class WebsiteBuilder {
247241
if (!listOf(
248242
253,
249243
254,
250-
255
244+
255,
251245
).contains(it.id.toInt())
252246
) {
253247
classes = setOf("invert-color")

0 commit comments

Comments
 (0)