- 1 year ago
set multiple PATH variables in CMD
Comment
1 / 1
In CMD, you can set multiple PATH variables by separating each path with a semicolon (;
). Here's an example of how to set multiple PATH variables in CMD:
cssset PATH=C:\Path1;C:\Path2;%PATH%
In the example above, we're setting the PATH variable with three paths: C:\Path1
, C:\Path2
, and %PATH%
. The %PATH%
part is used to append the existing PATH variable value, ensuring that any previously set paths are retained.
By using the semicolon as a separator, you can add multiple paths to the PATH variable in CMD. Each path specifies a directory where the system searches for executable files when you enter a command without specifying the full path.
Remember to separate each path with a semicolon and use the %PATH%
syntax to append the existing PATH variable value if needed.