Possible Duplicate:
Get current folder name by a DOS command?
In my batch file, I have,
SET currentFolder=%CD%
echo "%currentFolder%"
Prints the whole directory path.
C:\www\scritps\
I need to get scripts
alone
Possible Duplicate:
Get current folder name by a DOS command?
In my batch file, I have,
SET currentFolder=%CD%
echo "%currentFolder%"
Prints the whole directory path.
C:\www\scritps\
I need to get scripts
alone
There really isn't an easy way to do it. This works in a .bat file:
for %%* in (.) do @echo %%~n*
.
in their names. Any tips?
Commented
Jan 11, 2017 at 1:07