Setting props Upright with LUA

do you know when you hold SHIFT+E with your physgun in an attempt to make a prop Vertically upright?
How can i code a function that DOES this?

in more detail:
When “IsHolding” = True, and you are also pressing SHIFT, Run the command to make the 'thing" that you are holding Vertically upright, no matter what position it is in.
how would i do this?