Skip to content

Commit 5d55821

Browse files
committed
cherry-studio: remove update button
1 parent 9922c5a commit 5d55821

File tree

2 files changed

+41
-12
lines changed

2 files changed

+41
-12
lines changed
Lines changed: 40 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,15 @@
11
diff --git a/src/main/services/AppUpdater.ts b/src/main/services/AppUpdater.ts
2-
index bdfb8e3cc..cc9ab2e52 100644
2+
index bdfb8e3cc..aac1e1f49 100644
33
--- a/src/main/services/AppUpdater.ts
44
+++ b/src/main/services/AppUpdater.ts
5-
@@ -26,8 +26,8 @@ export default class AppUpdater {
6-
constructor() {
7-
autoUpdater.logger = logger as Logger
8-
autoUpdater.forceDevUpdateConfig = !app.isPackaged
9-
- autoUpdater.autoDownload = configManager.getAutoUpdate()
10-
- autoUpdater.autoInstallOnAppQuit = configManager.getAutoUpdate()
11-
+ autoUpdater.autoDownload = false
12-
+ autoUpdater.autoInstallOnAppQuit = false
13-
autoUpdater.requestHeaders = {
14-
...autoUpdater.requestHeaders,
15-
'User-Agent': generateUserAgent()
5+
@@ -123,6 +123,7 @@ export default class AppUpdater {
6+
}
7+
8+
public setAutoUpdate(isActive: boolean) {
9+
+ isActive = false
10+
autoUpdater.autoDownload = isActive
11+
autoUpdater.autoInstallOnAppQuit = isActive
12+
}
1613
diff --git a/src/main/services/ConfigManager.ts b/src/main/services/ConfigManager.ts
1714
index 5f5be2c72..1d0c5178b 100644
1815
--- a/src/main/services/ConfigManager.ts
@@ -26,3 +23,34 @@ index 5f5be2c72..1d0c5178b 100644
2623
}
2724

2825
setAutoUpdate(value: boolean) {
26+
diff --git a/src/renderer/src/pages/settings/AboutSettings.tsx b/src/renderer/src/pages/settings/AboutSettings.tsx
27+
index 72a545f4b..64e8e7de0 100644
28+
--- a/src/renderer/src/pages/settings/AboutSettings.tsx
29+
+++ b/src/renderer/src/pages/settings/AboutSettings.tsx
30+
@@ -216,26 +216,9 @@ const AboutSettings: FC = () => {
31+
</Tag>
32+
</VersionWrapper>
33+
</Row>
34+
- {!isPortable && (
35+
- <CheckUpdateButton
36+
- onClick={onCheckUpdate}
37+
- loading={update.checking}
38+
- disabled={update.downloading || update.checking}>
39+
- {update.downloading
40+
- ? t('settings.about.downloading')
41+
- : update.available
42+
- ? t('settings.about.checkUpdate.available')
43+
- : t('settings.about.checkUpdate.label')}
44+
- </CheckUpdateButton>
45+
- )}
46+
</AboutHeader>
47+
{!isPortable && (
48+
<>
49+
- <SettingDivider />
50+
- <SettingRow>
51+
- <SettingRowTitle>{t('settings.general.auto_check_update.title')}</SettingRowTitle>
52+
- <Switch value={autoCheckUpdate} onChange={(v) => setAutoCheckUpdate(v)} />
53+
- </SettingRow>
54+
<SettingDivider />
55+
<SettingRow>
56+
<SettingRowTitle>{t('settings.general.test_plan.title')}</SettingRowTitle>

app-utils/cherry-studio/spec

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
VER=1.5.9
2+
REL=1
23
SRCS="git::commit=tags/v${VER}::https://github.com/CherryHQ/cherry-studio"
34
CHKSUMS="SKIP"
45
CHKUPDATE="anitya::id=379206"

0 commit comments

Comments
 (0)