mirror of
https://github.com/reactos/reactos.git
synced 2025-07-23 02:53:38 +00:00
- Implement SHIFT /n.
- Make prompt code $T and %TIME% have the hours space-padded, not zero-padded. - Allow delayed expansion in the parameter of IF ERRORLEVEL. svn path=/trunk/; revision=40084
This commit is contained in:
parent
466a9064a2
commit
3a52766a90
5 changed files with 26 additions and 9 deletions
|
@ -91,7 +91,7 @@ LPTSTR FindArg(TCHAR Char, BOOL *IsParam0)
|
|||
if (n < 0 || n > 9)
|
||||
return NULL;
|
||||
|
||||
n += bc->shiftlevel;
|
||||
n = bc->shiftlevel[n];
|
||||
*IsParam0 = (n == 0);
|
||||
pp = bc->params;
|
||||
|
||||
|
@ -207,6 +207,7 @@ BOOL Batch (LPTSTR fullname, LPTSTR firstword, LPTSTR param, PARSED_COMMAND *Cmd
|
|||
{
|
||||
BATCH_CONTEXT new;
|
||||
LPFOR_CONTEXT saved_fc;
|
||||
INT i;
|
||||
|
||||
HANDLE hFile;
|
||||
SetLastError(0);
|
||||
|
@ -260,7 +261,8 @@ BOOL Batch (LPTSTR fullname, LPTSTR firstword, LPTSTR param, PARSED_COMMAND *Cmd
|
|||
bc->hBatchFile = hFile;
|
||||
SetFilePointer (bc->hBatchFile, 0, NULL, FILE_BEGIN);
|
||||
bc->bEcho = bEcho; /* Preserve echo across batch calls */
|
||||
bc->shiftlevel = 0;
|
||||
for (i = 0; i < 10; i++)
|
||||
bc->shiftlevel[i] = i;
|
||||
|
||||
bc->params = BatchParams (firstword, param);
|
||||
//
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue