To get back to your comment about the power switch killing power and it not being the best way to cleanly power down even a Linux PC, you are spot on.
Its not the best idea to just jerk the power.
Here is an example for a Linux PC that we have all probably heard about; the Raspberry Pi.
The short version is that you will need to install a button that will run a script that shuts the PC down in a very calm manor.
So, depending on the PC you are running, and depending on what I/O ports it has you will have to be guided by what the PC has.