[Toc][Index]

UNSET - Remove environment variables

 
 Purpose:    Remove variables from the environment. 
             
 Format:     UNSET  [/Q /R file ] name ... 
                 or 
             UNSET * 
             
             name :  One or more variables to remove. 
             file :  One or more files containing variables definitions. 
             
             /M(uiet)                        /R(ead from file) 
             /Q(uiet)                        
 
 See also:  ESET and SET. 
 Usage 
 UNSET removes one or more variables from the environment.  For example, 
 to remove the variable CMDLINE: 

 
         [c:\] unset cmdline
 
 
 If you use the command UNSET *, all of the environment variables will be 
 deleted: 

 
         [c:\] unset *
 
 
 UNSET can be used in a batch file, in conjunction with the SETLOCAL and 
 ENDLOCAL commands, to clear the environment of variables that may cause 
 problems for applications run from that batch file. 
 For more information on environment variables, see the SET command and 
 the general discussion of the environment. 
 Use caution when removing environment variables, and especially when 
 using UNSET *.  Many programs will not work properly without certain 
 environment variables; for example, CMD.EXE uses PATH and DPATH. 
 Options 
    /Q:     (Quiet) Prevents UNSET from displaying an error message if one 
            or more of the variables does not exist.  This option is most 
            useful in batch files, for removing a group of variables when 
            some of the variables may not have been defined. 
    /R:     (Read) Read environment variables to UNSET from a file.  This 
            much faster than using multiple UNSET commands in a batch 
            file, and can be more selective than UNSET *.  The file format 
            should be the same format as that used by the SET /R command. 
 

Created using Inf-PHP v.2 (c) 2003 Yuri Prokushev
Created using Inf-HTML v.0.9b (c) 1995 Peter Childs