Skip to content

Commit

Permalink
优化
Browse files Browse the repository at this point in the history
  • Loading branch information
mgz0227 committed Feb 29, 2024
1 parent 37670dd commit ca4405a
Show file tree
Hide file tree
Showing 342 changed files with 1,591 additions and 1,591 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/automerge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,5 @@ jobs:
name: automerge
uses: "pascalgn/[email protected]"
env:
MERGE_FILTER_AUTHOR: "mgz0227"
MERGE_FILTER_AUTHOR: "jing332"
GITHUB_TOKEN: ${{ secrets.TOKEN }}
4 changes: 2 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ def gitCommits = Integer.parseInt('git rev-list HEAD --count'.execute().text.tri

android {
compileSdk 34
namespace 'com.github.mgz0227.tts_server_android'
namespace 'com.github.jing332.tts_server_android'
defaultConfig {
applicationId 'com.github.mgz0227.tts_server_android'
applicationId 'com.github.jing332.tts_server_android'
minSdk 21
targetSdk 34
versionCode gitCommits
Expand Down
2 changes: 1 addition & 1 deletion app/proguard-rules.pro
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
-keep class com.script.javascript.** { *; }

# 插件相关
-keep class com.github.mgz0227.tts_server_android.model.rhino.core.** { *; }
-keep class com.github.jing332.tts_server_android.model.rhino.core.** { *; }
-keep class cn.hutool.crypto.** { *; }
-keep class com.hankcs.hanlp.** { *; }

Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package com.github.mgz0227.tts_server_android
package com.github.jing332.tts_server_android

import androidx.test.ext.junit.runners.AndroidJUnit4
import com.github.mgz0227.tts_server_android.model.rhino.core.ext.JsExtensions
import com.github.mgz0227.tts_server_android.model.rhino.direct_link_upload.DirectUploadEngine
import com.github.jing332.tts_server_android.model.rhino.core.ext.JsExtensions
import com.github.jing332.tts_server_android.model.rhino.direct_link_upload.DirectUploadEngine
import org.junit.Test
import org.junit.runner.RunWith

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.github.mgz0227.tts_server_android
package com.github.jing332.tts_server_android

import androidx.test.ext.junit.runners.AndroidJUnit4
import org.junit.Test
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package com.github.mgz0227.tts_server_android
package com.github.jing332.tts_server_android

import android.util.Log
import androidx.test.ext.junit.runners.AndroidJUnit4
import com.github.mgz0227.tts_server_android.constant.AppConst
import com.github.mgz0227.tts_server_android.model.AnalyzeUrl
import com.github.jing332.tts_server_android.constant.AppConst
import com.github.jing332.tts_server_android.model.AnalyzeUrl
import org.junit.Assert.*
import org.junit.Test
import org.junit.runner.RunWith
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.github.mgz0227.tts_server_android
package com.github.jing332.tts_server_android

import androidx.test.ext.junit.runners.AndroidJUnit4
import com.drake.net.Net
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.github.mgz0227.tts_server_android
package com.github.jing332.tts_server_android

import androidx.test.ext.junit.runners.AndroidJUnit4
import cn.hutool.crypto.symmetric.SymmetricCrypto
Expand Down
6 changes: 3 additions & 3 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@
android:name=".compose.systts.speechrule.SpeechRuleManagerActivity"
android:exported="true"
android:label="@string/speech_rule_manager"
android:taskAffinity="com.github.mgz0227.tts_server_android.speechrule" />
android:taskAffinity="com.github.jing332.tts_server_android.speechrule" />
<activity
android:name=".ui.ExoPlayerActivity"
android:exported="false"
Expand All @@ -102,12 +102,12 @@
android:name=".compose.systts.plugin.PluginManagerActivity"
android:exported="true"
android:label="@string/plugin_manager"
android:taskAffinity="com.github.mgz0227.tts_server_android.plugin" />
android:taskAffinity="com.github.jing332.tts_server_android.plugin" />
<activity
android:name=".ui.ImportConfigActivity"
android:exported="true"
android:launchMode="singleTask"
android:taskAffinity="com.github.mgz0227.tts_server_android.import">
android:taskAffinity="com.github.jing332.tts_server_android.import">
<intent-filter>
<action android:name="android.intent.action.VIEW" />

Expand Down
2 changes: 1 addition & 1 deletion app/src/main/assets/help/app.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ version-1
### 此帮助文档可在左侧滑菜单打开。

[![Q群](https://img.shields.io/badge/Q%E7%BE%A4-124841768-blue.svg)](https://h5.qun.qq.com/s/hxc6YglYE8)
[![Issue](https://img.shields.io/badge/Github-Issue-greeb.svg)](https://github.com/mgz0227/tts-server-android/issues)
[![Issue](https://img.shields.io/badge/Github-Issue-greeb.svg)](https://github.com//tts-server-android/issues)
[![Dev](https://img.shields.io/github/actions/workflow/status/mgz0227/tts-server-android/test.yml?label=%E5%BC%80%E5%8F%91%E7%89%88)](https://github.com/mgz0227/tts-server-android/actions/workflows/test.yml)

# TTS Server
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
package com.github.mgz0227.tts_server_android
package com.github.jing332.tts_server_android

import android.annotation.SuppressLint
import android.app.Application
import android.content.Context
import android.content.Intent
import android.os.Process
import com.github.mgz0227.tts_server_android.model.hanlp.HanlpManager
import com.github.jing332.tts_server_android.model.hanlp.HanlpManager
import kotlinx.coroutines.DelicateCoroutinesApi
import kotlinx.coroutines.GlobalScope
import kotlinx.coroutines.launch
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
package com.github.mgz0227.tts_server_android
package com.github.jing332.tts_server_android

import android.annotation.SuppressLint
import android.content.Context
import android.os.Build
import android.os.LocaleList
import androidx.appcompat.app.AppCompatDelegate
import androidx.core.os.LocaleListCompat
import com.github.mgz0227.tts_server_android.utils.FileUtils
import com.github.mgz0227.tts_server_android.utils.sysConfiguration
import com.github.jing332.tts_server_android.utils.FileUtils
import com.github.jing332.tts_server_android.utils.sysConfiguration
import java.io.File
import java.util.*

Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
package com.github.mgz0227.tts_server_android
package com.github.jing332.tts_server_android

import android.content.Context
import com.github.mgz0227.tts_server_android.constant.AppConst
import com.github.mgz0227.tts_server_android.utils.ClipboardUtils
import com.github.mgz0227.tts_server_android.utils.longToast
import com.github.mgz0227.tts_server_android.utils.runOnUI
import com.github.jing332.tts_server_android.constant.AppConst
import com.github.jing332.tts_server_android.utils.ClipboardUtils
import com.github.jing332.tts_server_android.utils.longToast
import com.github.jing332.tts_server_android.utils.runOnUI
import tts_server_lib.Tts_server_lib
import java.time.LocalDateTime

Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
package com.github.mgz0227.tts_server_android
package com.github.jing332.tts_server_android

import android.content.Context
import android.content.Intent
import androidx.core.content.pm.ShortcutInfoCompat
import androidx.core.content.pm.ShortcutManagerCompat
import androidx.core.graphics.drawable.IconCompat
import com.github.mgz0227.tts_server_android.compose.systts.plugin.PluginManagerActivity
import com.github.mgz0227.tts_server_android.compose.systts.replace.ReplaceManagerActivity
import com.github.mgz0227.tts_server_android.compose.systts.speechrule.SpeechRuleManagerActivity
import com.github.mgz0227.tts_server_android.ui.forwarder.MsForwarderSwitchActivity
import com.github.mgz0227.tts_server_android.ui.forwarder.SystemForwarderSwitchActivity
import com.github.jing332.tts_server_android.compose.systts.plugin.PluginManagerActivity
import com.github.jing332.tts_server_android.compose.systts.replace.ReplaceManagerActivity
import com.github.jing332.tts_server_android.compose.systts.speechrule.SpeechRuleManagerActivity
import com.github.jing332.tts_server_android.ui.forwarder.MsForwarderSwitchActivity
import com.github.jing332.tts_server_android.ui.forwarder.SystemForwarderSwitchActivity

object ShortCuts {
private inline fun <reified T> buildIntent(context: Context): Intent {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.github.mgz0227.tts_server_android.bean
package com.github.jing332.tts_server_android.bean


import kotlinx.serialization.SerialName
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.github.mgz0227.tts_server_android.bean
package com.github.jing332.tts_server_android.bean

import kotlinx.serialization.SerialName
import kotlinx.serialization.Serializable
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.github.mgz0227.tts_server_android.bean
package com.github.jing332.tts_server_android.bean

import kotlinx.serialization.SerialName
import kotlinx.serialization.Serializable
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.github.mgz0227.tts_server_android.compose
package com.github.jing332.tts_server_android.compose

import android.content.Intent
import androidx.compose.foundation.clickable
Expand All @@ -23,10 +23,10 @@ import androidx.compose.ui.text.style.TextAlign
import androidx.compose.ui.text.style.TextAlign.Companion
import androidx.compose.ui.unit.dp
import androidx.core.net.toUri
import com.github.mgz0227.tts_server_android.BuildConfig
import com.github.mgz0227.tts_server_android.R
import com.github.mgz0227.tts_server_android.compose.widgets.AppDialog
import com.github.mgz0227.tts_server_android.compose.widgets.AppLauncherIcon
import com.github.jing332.tts_server_android.BuildConfig
import com.github.jing332.tts_server_android.R
import com.github.jing332.tts_server_android.compose.widgets.AppDialog
import com.github.jing332.tts_server_android.compose.widgets.AppLauncherIcon

@Composable
fun AboutDialog(onDismissRequest: () -> Unit) {
Expand Down Expand Up @@ -68,7 +68,7 @@ fun AboutDialog(onDismissRequest: () -> Unit) {
modifier = Modifier
.clip(MaterialTheme.shapes.small)
.clickable {
openUrl("https://github.com/mgz0227/tts-server-android")
openUrl("https://github.com/jing332/tts-server-android")
}
.padding(vertical = 8.dp)
.fillMaxWidth(),
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.github.mgz0227.tts_server_android.compose
package com.github.jing332.tts_server_android.compose

import android.content.Intent
import android.net.Uri
Expand All @@ -24,12 +24,12 @@ import androidx.compose.ui.res.stringResource
import androidx.compose.ui.text.style.TextAlign
import androidx.compose.ui.tooling.preview.Preview
import androidx.compose.ui.unit.dp
import com.github.mgz0227.tts_server_android.R
import com.github.mgz0227.tts_server_android.compose.widgets.AppDialog
import com.github.mgz0227.tts_server_android.compose.widgets.Markdown
import com.github.mgz0227.tts_server_android.constant.AppConst
import com.github.mgz0227.tts_server_android.model.updater.AppUpdateChecker
import com.github.mgz0227.tts_server_android.utils.ClipboardUtils
import com.github.jing332.tts_server_android.R
import com.github.jing332.tts_server_android.compose.widgets.AppDialog
import com.github.jing332.tts_server_android.compose.widgets.Markdown
import com.github.jing332.tts_server_android.constant.AppConst
import com.github.jing332.tts_server_android.model.updater.AppUpdateChecker
import com.github.jing332.tts_server_android.utils.ClipboardUtils

@Preview
@Composable
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.github.mgz0227.tts_server_android.compose
package com.github.jing332.tts_server_android.compose

import androidx.compose.runtime.Composable
import androidx.compose.runtime.LaunchedEffect
Expand All @@ -8,10 +8,10 @@ import androidx.compose.runtime.remember
import androidx.compose.runtime.setValue
import androidx.compose.ui.platform.LocalContext
import com.drake.net.utils.withIO
import com.github.mgz0227.tts_server_android.R
import com.github.mgz0227.tts_server_android.model.updater.AppUpdateChecker
import com.github.mgz0227.tts_server_android.model.updater.UpdateResult
import com.github.mgz0227.tts_server_android.utils.longToast
import com.github.jing332.tts_server_android.R
import com.github.jing332.tts_server_android.model.updater.AppUpdateChecker
import com.github.jing332.tts_server_android.model.updater.UpdateResult
import com.github.jing332.tts_server_android.utils.longToast
import kotlinx.coroutines.CancellationException

@Composable
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.github.mgz0227.tts_server_android.compose
package com.github.jing332.tts_server_android.compose

import android.os.Bundle
import androidx.activity.compose.setContent
Expand All @@ -17,8 +17,8 @@ import androidx.compose.material3.TopAppBar
import androidx.compose.runtime.Composable
import androidx.compose.ui.Modifier
import androidx.compose.ui.res.stringResource
import com.github.mgz0227.tts_server_android.R
import com.github.mgz0227.tts_server_android.compose.theme.AppTheme
import com.github.jing332.tts_server_android.R
import com.github.jing332.tts_server_android.compose.theme.AppTheme
import com.mikepenz.aboutlibraries.ui.compose.LibrariesContainer
import com.mikepenz.aboutlibraries.ui.compose.LibraryDefaults

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
@file:Suppress("DEPRECATION")

package com.github.mgz0227.tts_server_android.compose
package com.github.jing332.tts_server_android.compose

import android.Manifest
import android.annotation.SuppressLint
Expand Down Expand Up @@ -79,29 +79,29 @@ import androidx.navigation.compose.NavHost
import androidx.navigation.compose.composable
import androidx.navigation.compose.currentBackStackEntryAsState
import androidx.navigation.compose.rememberNavController
import com.github.mgz0227.tts_server_android.BuildConfig
import com.github.mgz0227.tts_server_android.R
import com.github.mgz0227.tts_server_android.ShortCuts
import com.github.mgz0227.tts_server_android.compose.forwarder.ms.MsTtsForwarderScreen
import com.github.mgz0227.tts_server_android.compose.forwarder.systts.SystemTtsForwarderScreen
import com.github.mgz0227.tts_server_android.compose.nav.NavRoutes
import com.github.mgz0227.tts_server_android.compose.settings.SettingsScreen
import com.github.mgz0227.tts_server_android.compose.systts.SystemTtsScreen
import com.github.mgz0227.tts_server_android.compose.systts.list.edit.TtsEditContainerScreen
import com.github.mgz0227.tts_server_android.compose.theme.AppTheme
import com.github.mgz0227.tts_server_android.compose.widgets.AppLauncherIcon
import com.github.mgz0227.tts_server_android.conf.AppConfig
import com.github.mgz0227.tts_server_android.constant.AppConst
import com.github.mgz0227.tts_server_android.data.appDb
import com.github.mgz0227.tts_server_android.data.entities.systts.SystemTts
import com.github.mgz0227.tts_server_android.model.speech.tts.ITextToSpeechEngine
import com.github.mgz0227.tts_server_android.service.systts.SystemTtsService
import com.github.mgz0227.tts_server_android.ui.AppHelpDocumentActivity
import com.github.mgz0227.tts_server_android.utils.MyTools.killBattery
import com.github.mgz0227.tts_server_android.utils.clone
import com.github.mgz0227.tts_server_android.utils.longToast
import com.github.mgz0227.tts_server_android.utils.performLongPress
import com.github.mgz0227.tts_server_android.utils.toast
import com.github.jing332.tts_server_android.BuildConfig
import com.github.jing332.tts_server_android.R
import com.github.jing332.tts_server_android.ShortCuts
import com.github.jing332.tts_server_android.compose.forwarder.ms.MsTtsForwarderScreen
import com.github.jing332.tts_server_android.compose.forwarder.systts.SystemTtsForwarderScreen
import com.github.jing332.tts_server_android.compose.nav.NavRoutes
import com.github.jing332.tts_server_android.compose.settings.SettingsScreen
import com.github.jing332.tts_server_android.compose.systts.SystemTtsScreen
import com.github.jing332.tts_server_android.compose.systts.list.edit.TtsEditContainerScreen
import com.github.jing332.tts_server_android.compose.theme.AppTheme
import com.github.jing332.tts_server_android.compose.widgets.AppLauncherIcon
import com.github.jing332.tts_server_android.conf.AppConfig
import com.github.jing332.tts_server_android.constant.AppConst
import com.github.jing332.tts_server_android.data.appDb
import com.github.jing332.tts_server_android.data.entities.systts.SystemTts
import com.github.jing332.tts_server_android.model.speech.tts.ITextToSpeechEngine
import com.github.jing332.tts_server_android.service.systts.SystemTtsService
import com.github.jing332.tts_server_android.ui.AppHelpDocumentActivity
import com.github.jing332.tts_server_android.utils.MyTools.killBattery
import com.github.jing332.tts_server_android.utils.clone
import com.github.jing332.tts_server_android.utils.longToast
import com.github.jing332.tts_server_android.utils.performLongPress
import com.github.jing332.tts_server_android.utils.toast
import com.google.accompanist.permissions.ExperimentalPermissionsApi
import com.google.accompanist.permissions.isGranted
import com.google.accompanist.permissions.rememberPermissionState
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.github.mgz0227.tts_server_android.compose
package com.github.jing332.tts_server_android.compose

import android.view.HapticFeedbackConstants
import androidx.compose.animation.core.animateDpAsState
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.github.mgz0227.tts_server_android.compose.backup
package com.github.jing332.tts_server_android.compose.backup

import androidx.activity.compose.rememberLauncherForActivityResult
import androidx.compose.foundation.layout.Arrangement
Expand All @@ -20,12 +20,12 @@ import androidx.compose.ui.Modifier
import androidx.compose.ui.platform.LocalContext
import androidx.compose.ui.res.stringResource
import androidx.lifecycle.viewmodel.compose.viewModel
import com.github.mgz0227.tts_server_android.R
import com.github.mgz0227.tts_server_android.compose.widgets.AppDialog
import com.github.mgz0227.tts_server_android.compose.widgets.TextCheckBox
import com.github.mgz0227.tts_server_android.ui.AppActivityResultContracts
import com.github.mgz0227.tts_server_android.ui.FilePickerActivity
import com.github.mgz0227.tts_server_android.ui.view.AppDialogs.displayErrorDialog
import com.github.jing332.tts_server_android.R
import com.github.jing332.tts_server_android.compose.widgets.AppDialog
import com.github.jing332.tts_server_android.compose.widgets.TextCheckBox
import com.github.jing332.tts_server_android.ui.AppActivityResultContracts
import com.github.jing332.tts_server_android.ui.FilePickerActivity
import com.github.jing332.tts_server_android.ui.view.AppDialogs.displayErrorDialog
import kotlinx.coroutines.launch

@Composable
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.github.mgz0227.tts_server_android.compose.backup
package com.github.jing332.tts_server_android.compose.backup

import android.content.Intent
import android.os.Bundle
Expand All @@ -24,10 +24,10 @@ import androidx.compose.runtime.remember
import androidx.compose.runtime.setValue
import androidx.compose.ui.Modifier
import androidx.compose.ui.res.stringResource
import com.github.mgz0227.tts_server_android.R
import com.github.mgz0227.tts_server_android.compose.settings.BasePreferenceWidget
import com.github.mgz0227.tts_server_android.compose.theme.AppTheme
import com.github.mgz0227.tts_server_android.utils.FileUtils.readBytes
import com.github.jing332.tts_server_android.R
import com.github.jing332.tts_server_android.compose.settings.BasePreferenceWidget
import com.github.jing332.tts_server_android.compose.theme.AppTheme
import com.github.jing332.tts_server_android.utils.FileUtils.readBytes

class BackupRestoreActivity : AppCompatActivity() {
companion object {
Expand Down
Loading

0 comments on commit ca4405a

Please sign in to comment.