Skip to content

Commit ea754c4

Browse files
App Version 1.4 Code 9
1 parent f400ba9 commit ea754c4

File tree

6 files changed

+169
-31
lines changed

6 files changed

+169
-31
lines changed

commands.js

+11-15
Original file line numberDiff line numberDiff line change
@@ -48,40 +48,40 @@ const systemTweaksOptions = [
4848
},
4949
{
5050
id: 'adv_sys2',
51-
command: 'reg add "HKCU\\Control Panel\\Desktop" /v MinAnimate /t REG_SZ /d 0 /f'
51+
command: 'reg add "HKLM\\SOFTWARE\\Policies\\Microsoft\\Windows Search" /v AllowCortana /t REG_DWORD /d 0 /f'
5252
},
5353
{
5454
id: 'adv_sys3',
55-
command: 'reg add "HKLM\\SOFTWARE\\Policies\\Microsoft\\Windows Search" /v AllowCortana /t REG_DWORD /d 0 /f'
55+
command: 'sc.exe config "SysMain" start=disabled'
5656
},
5757
{
5858
id: 'adv_sys4',
59-
command: 'sc.exe config "SysMain" start=disabled'
59+
command: 'reg add "HKLM\\SOFTWARE\\Policies\\Microsoft\\Windows Defender" /v DisableAntiSpyware /t REG_DWORD /d 1 /f'
6060
},
6161
{
6262
id: 'adv_sys5',
63-
command: 'reg add "HKLM\\SOFTWARE\\Policies\\Microsoft\\Windows Defender" /v DisableAntiSpyware /t REG_DWORD /d 1 /f'
63+
command: 'reg add "HKLM\\SOFTWARE\\Policies\\Microsoft\\Windows\\Personalization" /v NoLockScreen /t REG_DWORD /d 1 /f'
6464
},
6565
{
6666
id: 'adv_sys6',
67-
command: 'reg add "HKLM\\SOFTWARE\\Policies\\Microsoft\\Windows\\Personalization" /v NoLockScreen /t REG_DWORD /d 1 /f'
67+
command: 'reg add "HKLM\\SOFTWARE\\Microsoft\\Windows\\Windows Error Reporting" /v Disabled /t REG_DWORD /d 1 /f'
6868
},
6969
{
7070
id: 'adv_sys7',
71-
command: 'reg add "HKLM\\SOFTWARE\\Microsoft\\Windows\\Windows Error Reporting" /v Disabled /t REG_DWORD /d 1 /f'
71+
command: 'reg add "HKLM\\SYSTEM\\CurrentControlSet\\Control\\Session Manager" /v SessionManager /t REG_SZ /d "Optimized" /f'
7272
},
7373
{
7474
id: 'adv_sys8',
75-
command: 'reg add "HKLM\\SYSTEM\\CurrentControlSet\\Control\\Session Manager" /v SessionManager /t REG_SZ /d "Optimized" /f'
75+
command: 'powercfg /setacvalueindex SCHEME_CURRENT SUB_DISK DISKIDLE 0'
7676
},
7777
{
7878
id: 'adv_sys9',
79-
command: 'powercfg /setacvalueindex SCHEME_CURRENT SUB_DISK DISKIDLE 0'
79+
command: 'reg add "HKCU\\Software\\Microsoft\\Windows\\CurrentVersion\\BackgroundAccessApplications" /v GlobalUserDisabled /t REG_DWORD /d 1 /f'
8080
},
8181
{
8282
id: 'adv_sys10',
83-
command: 'reg add "HKCU\\Software\\Microsoft\\Windows\\CurrentVersion\\BackgroundAccessApplications" /v GlobalUserDisabled /t REG_DWORD /d 1 /f'
84-
}
83+
command: 'reg add "HKLM\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Policies\\System" /v DisableStatusMessages /t REG_DWORD /d 0 /f; reg add "HKLM\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Policies\\System" /v VerboseStatus /t REG_DWORD /d 1 /f'
84+
},
8585
];
8686

8787
const networkToolsOptions = [
@@ -134,14 +134,10 @@ const networkTweaksOptions = [
134134
},
135135
{
136136
id: 'adv_net8',
137-
command: 'ipconfig /flushdns'
138-
},
139-
{
140-
id: 'adv_net9',
141137
command: 'netsh int tcp set global autotuninglevel=disabled'
142138
},
143139
{
144-
id: 'adv_net10',
140+
id: 'adv_net9',
145141
command: 'dism /online /norestart /disable-feature /featurename:SMB1Protocol'
146142
}
147143
];

index.html

+3-1
Original file line numberDiff line numberDiff line change
@@ -790,6 +790,7 @@ <h4 class="sub-section-heading" style="margin-top: 8px !important;">Performance
790790
<label><input type="checkbox" value="adv_sys3" checked /> Disable Superfetch</label>
791791
<label><input type="checkbox" value="adv_sys7" checked /> Optimize Registry Performance</label>
792792
<label><input type="checkbox" value="adv_sys8" checked /> Enable Disk Write Caching</label>
793+
<label><input type="checkbox" value="adv_sys10" checked /> Enable System Verbose</label>
793794
</div>
794795

795796
<h4 class="sub-section-heading">Search &amp; Security</h4>
@@ -962,7 +963,7 @@ <h4 class="sub-section-heading">Cleanup &amp; Optimization</h4>
962963
<div class="tab" id="aboutTab">
963964
<div class="about-section">
964965
<img src="logo.png" />
965-
<p><strong>Version:</strong> 1.4-8</p>
966+
<p><strong>Version:</strong> 1.4-9</p>
966967
<p><strong>Developed by:</strong> AlphaSystem</p>
967968
<p><strong>Description:</strong> OptiForge is a system optimization tool designed to streamline Windows performance, enhance privacy, and maximize system efficiency. Leveraging advanced algorithms and real-time monitoring, OptiForge delivers a smoother, faster, and more secure computing experience.</p>
968969
<p><strong>Why "OptiForge":</strong> The name "OptiForge" is a fusion of two core concepts. <em>Opti</em> stands for "optimization," reflecting our commitment to enhancing system performance, while <em>Forge</em> suggests the craftsmanship and precision of building a robust, finely tuned system—much like a blacksmith forges a reliable tool.</p>
@@ -1146,6 +1147,7 @@ <h3>Command Details</h3>
11461147
adv_sys7: 'reg add "HKLM\\SYSTEM\\CurrentControlSet\\Control\\Session Manager" /v SessionManager /t REG_SZ /d "Optimized" /f',
11471148
adv_sys8: 'powercfg /setacvalueindex SCHEME_CURRENT SUB_DISK DISKIDLE 0',
11481149
adv_sys9: 'reg add "HKCU\\Software\\Microsoft\\Windows\\CurrentVersion\\BackgroundAccessApplications" /v GlobalUserDisabled /t REG_DWORD /d 1 /f',
1150+
adv_sys10: 'reg add "HKLM\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Policies\\System" /v DisableStatusMessages /t REG_DWORD /d 0 /f; reg add "HKLM\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Policies\\System" /v VerboseStatus /t REG_DWORD /d 1 /f',
11491151

11501152
adv_net1: 'reg add "HKLM\\SYSTEM\\CurrentControlSet\\Services\\QoS\\Parameters" /v Enabled /t REG_DWORD /d 1 /f',
11511153
adv_net2: 'reg add "HKLM\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Multimedia\\SystemProfile" /v NetworkThrottlingIndex /t REG_DWORD /d 0 /f',

main.js

+21-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
const { app, BrowserWindow, Menu } = require('electron');
1+
const { app, dialog, BrowserWindow, Menu } = require('electron');
22
const path = require('path');
33

44
Menu.setApplicationMenu(null);
@@ -20,6 +20,22 @@ function log(message, level = 'info') {
2020
}
2121
}
2222

23+
async function checkAdminPrivileges() {
24+
try {
25+
const { default: isElevated } = await import('is-elevated');
26+
const elevated = await isElevated();
27+
if (!elevated) {
28+
log('Application is not running with administrator privileges', 'warn');
29+
dialog.showErrorBox('Admin Rights Required', 'This application requires administrator privileges to run. Please restart the application as an administrator.');
30+
app.quit();
31+
} else {
32+
log('Application is running with administrator privileges', 'info');
33+
}
34+
} catch (error) {
35+
log(`Error checking admin privileges: ${error.message}`, 'error');
36+
}
37+
}
38+
2339
function createWindow() {
2440
const win = new BrowserWindow({
2541
width: 1152,
@@ -39,8 +55,11 @@ function createWindow() {
3955
win.loadFile('index.html');
4056
}
4157

42-
app.whenReady().then(() => {
58+
app.whenReady().then(async () => {
4359
log("App is ready");
60+
61+
await checkAdminPrivileges();
62+
4463
createWindow();
4564

4665
require('./apps');

0 commit comments

Comments
 (0)