@echo off
rem Save current directory
set curdir=%cd%
echo %cd%
rem Change current directory
cd ..\..
echo %cd%
rem Restore current directory
cd %curdir%
echo %cd%
Code above produces the following output:C:\Users\vurdalakov\github\code examples
C:\Users\vurdalakov
C:\Users\vurdalakov\github\code examples
No comments:
Post a Comment