Skip to content

Commit

Permalink
add menu to open configuration folder
Browse files Browse the repository at this point in the history
  • Loading branch information
jeanfbrito committed Jul 12, 2024
1 parent 6fc447a commit e1f5ee2
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/i18n/en.i18n.json
Original file line number Diff line number Diff line change
Expand Up @@ -298,6 +298,7 @@
"showServerList": "Server list",
"showTrayIcon": "Tray icon",
"toggleDevTools": "Toggle &DevTools",
"openConfigFolder": "Open &Configuration Folder",
"undo": "&Undo",
"unhide": "Show All",
"viewMenu": "&View",
Expand Down
11 changes: 11 additions & 0 deletions src/ui/main/menuBar.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import path from 'path';

import type { MenuItemConstructorOptions } from 'electron';
import { Menu, app, shell, BrowserWindow } from 'electron';
import i18next from 'i18next';
Expand Down Expand Up @@ -589,6 +591,15 @@ const createHelpMenu = createSelector(
browserWindow.webContents.toggleDevTools();
},
},
{
id: 'openConfigFolder',
label: t('menus.openConfigFolder'),
click: async () => {
shell.showItemInFolder(
path.join(app.getPath('userData'), 'config.json')
);
},
},
{ type: 'separator' },
{
id: 'clearTrustedCertificates',
Expand Down

0 comments on commit e1f5ee2

Please sign in to comment.