My favorites | Sign in
Project Home Downloads Wiki Issues Source
Checkout   Browse   Changes    
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
:: Populates the variable NAME with the the current working directory.
:: If NAME is not specified the current direcory will be printed.
::
:: @usage call :tempname NAME
::
:: @param string
:pwd
setlocal

if "%CD:~-1%" == "\" (
set pwd=%CD%
) else (
set pwd=%CD%\
)

if "%~1" == "" (
echo.%pwd%
endlocal
goto :EOF
)

endlocal && set %~1=%pwd%
goto :EOF

Change log

r18 by Ildar.Shaimordanov on Feb 12, 2010   Diff
[No log message]
Go to: 
Project members, sign in to write a code review

Older revisions

r14 by Ildar.Shaimordanov on Feb 11, 2010   Diff
[No log message]
r13 by Ildar.Shaimordanov on Feb 10, 2010   Diff
[No log message]
All revisions of this file

File info

Size: 400 bytes, 24 lines
Powered by Google Project Hosting