()
| 148 | }; |
| 149 | |
| 150 | export const restartSupervisedService = async (): Promise<void> => { |
| 151 | if (!executorAvailable()) { |
| 152 | throw new Error("Bundled executor binary is not available."); |
| 153 | } |
| 154 | const dataDir = join(app.getPath("home"), ".executor"); |
| 155 | const result = await runExecutor(["service", "restart"], { dataDir }); |
| 156 | if (result.code !== 0) { |
| 157 | throw new Error( |
| 158 | (result.stderr || result.stdout).trim() || "`executor service restart` failed.", |
| 159 | ); |
| 160 | } |
| 161 | }; |
no test coverage detected