This is a utility application that can launch anything with everything below defined at the same time:
- Privilege raised
- Run as different user
- Environment variable maniupate (prefix, postfix, and/or redefine)
- Passing arguments
- Shell execute (Supports open something which itself isn't an executable)
- Working directory change
This utility is specified and targeted to Windows platform only, it will not work on other platform even you try to run it with other CLR implementations.
Elevator.exe [options] [--] {command} [arguments...]
where options can be:
--vXXX
: Verb, aka. the action will take on the command/filename, define this to use shell execute, whereXXX
is the verb itself, it can beopen
,edit
,openasreadonly
,print
, etc.--runas
: Special action that raise privilege to administrator while launching.--eXXX=YYY
: SetsYYY
to environment variableXXX
.--eXXX
: Copy environment variableXXX
in current scope to new environment.--aXXX=YYY
: AppendsYYY
to environment variableXXX
.--pXXX=YYY
: PrependsYYY
to environment variableXXX
.--cd=YYY
: Sets working directory toYYY
.--wXXX
: Sets window style for new process, it can benormal
,hidden
,minimized
,maximized
, default isnormal
.--nowindow
: Sets new process lanuch without creating a new window to contain it.--nowait
: Do not wait until the target application exits. This may cause input problem if it is launched within interactive console.--login=XXX
: Run the process with different user asXXX
, you may pass as UPN format, such asuser@DNS_domain_name
.--loginpw=XXX
: Password. If you havelogin
defined and the user needs password, please provide with password.--loaduserprofile
: Load user profile, only have use when use withlogin
.
The option prefix can be --
, -
, or /
.