Skip to content

Commit 6387b34

Browse files
committed
feat(setting): run updates silently
1 parent f2cdf6a commit 6387b34

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/hooks/updates.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,11 @@ export const disabled = settings.register({
3030
category: 'Updates',
3131
});
3232

33-
const silent = settings.register();
33+
const silent = settings.register({
34+
name: 'Run automatic updates in the background',
35+
key: 'underscript.updates.silent',
36+
category: 'Updates',
37+
});
3438

3539
const frequency = settings.register({
3640
// TODO: translation
@@ -218,7 +222,7 @@ menu.addButton({
218222

219223
eventManager.on(':update', (auto) => {
220224
toast?.close();
221-
// if (auto) return;
225+
if (auto && silent.value()) return;
222226
// TODO: translation
223227
notify('Checking for updates. Please wait.');
224228
});

0 commit comments

Comments
 (0)