You can't.
The shift key isn't considered as a character key, so even if you access the terminal directly, you won't be able to detect this key.
Maybe you shouldn't have to. Imagine for example that you are using a US keyboard where numbers are accessible on the top row without modifiers, and also checking for the shift key. People with other keyboard layout may have to use shift modifiers to access the numbers. If your program react to this shift press, then your program is basically unusable. The same thing applies for other modifier keys : you may detect some of them only after a normal character key is pressed. Or worse, they may need to use the shift key to use 'enter' to run your program.
Also, what shift key do you want to monitor ? the one on the local machine, or the one where the user is ? remember that SSH exists and is commonly used to access a pseudoterminal remotely.
If you are root and want to monitor the Shift key on the local machine, you can read the evdev devices for events about the shift key. But this is only possible because of automatic key repeating, so you won't detect a shift key that is pressed right before running your program, but only a few second before.
Of course you can't do that on the remote machine, that would be a security flaw.
And anyway, why would you want to do that ? wouldn't an X application be the right thing to do in your case ?