grub4dos icon indicating copy to clipboard operation
grub4dos copied to clipboard

grub4dos-0.4.6a-2021-10-13.7z - error running batch files

Open steve6375 opened this issue 2 years ago • 12 comments

grub4dos-0.4.6a-2021-10-13.7z image With this grldr I get error running a batch file previous versions worked OK

May be caused by removing spaces fix ?

steve6375 avatar Oct 13 '21 09:10 steve6375

P.S. Please can you include \ext folder with utilities in all future zip files too?

steve6375 avatar Oct 13 '21 09:10 steve6375

echo 3
cat %sortlist% | call :copyfiles 
echo 4

image problem traced to this line in batch file which works OK with previous versions

Note that end of line MUST have a space to work cat %sortlist% | call :copyfiles [SPACE]

steve6375 avatar Oct 13 '21 10:10 steve6375

I don't think you should remove space from end of command lines I only asked for you to remove space from filename when passed to animation code - i.e. change animation code only

steve6375 avatar Oct 13 '21 10:10 steve6375

How to repeat the question

yaya2007 avatar Oct 13 '21 10:10 yaya2007

see #338

steve6375 avatar Oct 13 '21 10:10 steve6375

image image

!BAT
echo -v
echo -n FRED   
echo FRED

Cannot remove spaces from command line

steve6375 avatar Oct 13 '21 10:10 steve6375

cat %sortlist% | call :copyfiles [SPACE] What does'|' mean?

yaya2007 avatar Oct 13 '21 10:10 yaya2007

it is pipe symbol https://github.com/chenall/grub4dos/blob/0.4.6a/README_GRUB4DOS.txt image

steve6375 avatar Oct 13 '21 11:10 steve6375

example on same page image

steve6375 avatar Oct 13 '21 11:10 steve6375

使用2021-08-13版本的grldr测试,同样的问题。我感觉是 cat %sortlist% | call :copyfiles 这句脚本有问题。

!BAT set sortlist=/test.g4b cat %sortlist% | call :copyfiles goto :end

:copyfiles echo 5678

:end

yaya2007 avatar Oct 14 '21 00:10 yaya2007

The code works OK BUT you must add a space image image

steve6375 avatar Oct 14 '21 03:10 steve6375

See also the echo code above which has spaces at end of line

!BAT
echo -v
echo -n FRED   
echo FRED

image

You must change back the code Do NOT remove spaces from end of lines

steve6375 avatar Oct 14 '21 03:10 steve6375