r/PowerShell • • Aug 30 '26

Script Sharing Built an open-source Windows diagnostic tool in PowerShell/WPF for my thesis — feedback welcome!

Hey everyone,

I'm currently working on my IT Bachelor’s Thesis and building Fercero USB Tool — an open-source, multithreaded Windows diagnostic and repair utility (PowerShell + WPF Dark Mode GUI).

It's still a work in progress, but current features include:

  • Hardware Scan: OS/CPU/RAM info, VRAM, and S.M.A.R.T. disk health.
  • System Repair: DISM/SFC scans, Windows Update cache reset, TCP/IP & DNS flushes.
  • Error Lookup: Integrated database for Device Manager codes (1–54) & critical system logs.

Since this is actively in development, I’d love some code reviews, testing, and feedback from the community!

https://github.com/SvetozarA00/Fercero-USB-Tool.git

17 Upvotes

11 comments sorted by

3

u/StartAutomating Sep 02 '26

Please separate your concerns.

Having everything all in one file is not conducive to maintainability.

Having everything strongly coupled to a GUI is not conducive to reuseability.

Please separate each high-level concern you have into a separate file.

2

u/Michal_F Sep 02 '26

To me it looks ok. But why are you using .bat file ? In future you will need to create more complex structure and this approach don't look ideal... Also you have some block namin on polish language?

3

u/Nu11u5 Sep 02 '26 edited Sep 02 '26

It's a polyglotal batch wrapper. The file is both valid batch and PowerShell. Since PowerShell will not execute scripts by double-clicking, it is wrapped in a batch file with the first commands instructing it to rerun using PowerShell.

You could build it as an EXE for the same utility, but then the script is no longer inspectable.

3

u/Michal_F Sep 02 '26

Hi, this is complicated topic, as the script is readable, but will run with administrative rights and is easy to change. So this can create another Challenge for some other than hobby use case. I would prefer signed PS1 that could be run from bat file if needed. Bu this would create another challenges related to certificates :)

1

u/Nu11u5 Sep 02 '26

You can still sign the file as PowerShell, but Windows won't automatically recognize it as a signed file type. Microsoft even added authenticode to VBScript/JScript/WSH but didn't care to support Batch.

1

u/neotearoa Sep 02 '26

Will look deeper later, go check tmog if you haven't already. Nice work, have you separated the uac / non uac mode functions or do you elevate as needed?

1

u/Nardog14 Sep 03 '26

Nice. There are quite a few empty catch blocks that you may consider returning an error for.

1

u/badteeth3000 Sep 05 '26

Someone else did an interesting powershell diag take with advanced log reading that’s readonly so its without uac elevation that may inspire you at https://wdt.digital

1

u/skidleydee Sep 05 '26

If it's just for your degree don't change anything, if you really want to make something that people turn to you should probably focus more on error handling and returning useful information. I can't tell you how often I do a code review and everything looks good but once you start writing more verbose logs there are issues you would have never known about. 

1

u/derpingthederps 21d ago edited 21d ago

Some feedback from someone who loves a bit of PS and works in IT.

You may benefit from from dropping the GUI and BAT, and focusing on breaking it down into a Powershell module/scrips

A lot of IT staff won't be running around with USB's these days. We do have access to endpoint tools that allow script deployment or remote shell to execute modules.

Best bet would be to reduce the scope, master the utility, then revisit layering an interactive GUI.

-1

u/Flyerfan96 Sep 05 '26

Cookie cutter slop no thanks.