- Use _alloca instead of non-standard alloca
- Use _TCHAR instead of non-standard TCHAR
- Use _off_t instead of deprecated off_t
- Use _O_BINARY instead of O_BINARY
This GetPathCase function does
resolve the path with wildcard
pattern, and fix the alphabet
cases, by using
kernel32!FindFirstFile function.
Enable wildcard at the middle
of the file path in cmd.exe by
fixing this function.
JIRA issue: CORE-6609
JIRA issue: CORE-13906
- Fix GetPathCase function for
supporting wildcard at the
- middle of the file path.
- Make GetPathCase string-safe.
- Optimize GetPathCase.
CORE-8002
The switch enables or disables file/path completion in a unique
CMD instance. The defaulted values for the completion characters
are those mentioned in CMD's help (see also MSDN[^1]):
File: Ctrl-F (0x06); Directory: Ctrl-D (0x04)
Manual tests show that only /F:OFF explicitly disables completion.
Otherwise, using /F(anything else following) always enables completion
with the specific values described above.
[^1]: For additional details, see also
https://technet.microsoft.com/en-us/library/cc978715.aspxhttps://technet.microsoft.com/en-us/library/cc940805.aspx
Make DATE command output compatible.
JIRA issue: CORE-13848
- Add STRING_DATE_NOW resource string for
localizing "The current date is: ".
- Output by ConOutResPuts function.
Improve compatibility.
JIRA issue: CORE-8002
- Fix the default values of AutoCompletionChar
and PathCompletionChar in cmd.exe.
- Populate "SOFTWARE\Microsoft\Command
Processor" registry key like Win2k3 does.
Based on Hans Harder's patch.
Realize tracing cmd on console
output.
JIRA issue: CORE-6669
- Add FEATURE_DYNAMIC_TRACE
feature.
- Add CmdTrace function.
- Re-define FIXME, ERR, WARN,
and TRACE macros.
- Check CMDTRACE environment
variable. If it was "ON", then enable
dynamic trace.
* Remove a hardcoded copyright string and move into localizable resources.
* Remove the PROMPT environment variable from clean installs of ReactOS. By default, the command prompt uses $P$G (path + '>') as its prompt settings and does not require this environment variable. Clean installs of Windows Server 2003 do not include this environment variable either. I documented this environment variable in our wiki if anyone would like to set it on their own ReactOS installs.
* Remove the new line above the copyright notice when the information line is turned off.
CORE-16193, CORE-17031
ENABLE_PROCESSED_INPUT is necessary to correctly deal with CR-LF
and display it only when necessary. Fixes cmd:batch winetests.
Addendum to commit db219e45c
ConInString() should display a newline when it encounters the terminating
carriage-return pressed by the user for ending string output.
+ Remove the extra \n hacks in FilePromptYN[A].
Improve outputted strings from DATE and TIME commands.
+ Rename some STRING_***_ERROR defines.
CORE-18489
The "dir /w" command didn't look good due to unaligned columns.
- Add sdk/include/reactos/cjkcode.h header file.
- Add ConGetTextWidthA/W helper functions.
- Add base/shell/cmd/wcwidth.c to implement ConGetTextWidthW.
- Use ConGetTextWidth in DirPrintWideList function.
- Adjust some STRING_DIR_HELP5, STRING_DIR_HELP6 and STRING_DIR_HELP8 resource strings to make the column aligned.
CORE-17591
CORE-14096, CORE-8002
Patch based on an earlier fix attempt by Doug Lyons.
It should fix the problem observed by contributor 'whindsaks' in PR #5403.
This bug has always been present since the implementation of this feature
in commit a1eb1f6ba (r40024).
The expansion of %~dpX ennhanced variables used to incorrectly show some
directories in uppercase. For example:
```batch
:: testcmd.cmd
echo '%~dp0'
echo '%~dps0'
echo '%~s0'
```
would show:
```
P:\Documents and Settings\Administrator\Desktop>echo 'P:\Documents and Settings\Administrator\DESKTOP\'
'P:\Documents and Settings\Administrator\DESKTOP\'
P:\Documents and Settings\Administrator\Desktop>echo 'P:\DOCUME~1\ADMINI~1\DESKTOP\'
'P:\DOCUME~1\ADMINI~1\DESKTOP\'
P:\Documents and Settings\Administrator\Desktop>echo 'P:\DOCUME~1\ADMINI~1\DESKTOP\testcmd.cmd'
'P:\DOCUME~1\ADMINI~1\DESKTOP\testcmd.cmd'
```
instead of the correct:
```
P:\Documents and Settings\Administrator\Desktop>echo 'P:\Documents and Settings\Administrator\Desktop\'
'P:\Documents and Settings\Administrator\Desktop\'
P:\Documents and Settings\Administrator\Desktop>echo 'P:\DOCUME~1\ADMINI~1\DESKTOP\'
'P:\DOCUME~1\ADMINI~1\DESKTOP\'
P:\Documents and Settings\Administrator\Desktop>echo 'P:\DOCUME~1\ADMINI~1\DESKTOP\testcmd.cmd'
'P:\DOCUME~1\ADMINI~1\DESKTOP\testcmd.cmd'
```
The reason was a wrong handling of the presence (or absence) of the
"short" path format specifier 's' in those enhanced variables.
In the examples above, the "Desktop" sub-directory has a short-path
name available (because it is in a FAT partition). The short-path name
was used some times also even with the 's' specifier absent.
Co-authored-by: Doug Lyons <douglyons@douglyons.com>
Based on the Portuguese translation from Portugal.
Reviewed-by: Hermès Bélusca-Maïto <hermes.belusca-maito@reactos.org>
Reviewed-by: Stanislav Motylkov <x86corez@gmail.com>
Tested and compared with MS CMD.EXE when copying files within the
same directory, across directories and across drives.
This is not done for the MOVE, REN and REPLACE commands however.
CORE-18090
- Changed some wording according to the translation requirements.
- Fixed some mistakes.
- Changed my name.
Reviewed-by: He Yang <1160386205@qq.com>
Reviewed-by: Stanislav Motylkov <x86corez@gmail.com>
Reviewed all Chinese Simplified translation files and updated those
inappropriate or outdated ones.
Co-authored-by: Liu Wenyuan <15816141883@163.com>
Reviewed-by: Chan Chilung <eason066@gmail.com>
Reviewed-by: He Yang <1160386205@qq.com>
Reviewed-by: Zheng Jianping <robsean@126.com>
Reviewed-by: Luo Yufan <njlyf2011@hotmail.com>
Reviewed-by: Hermès Bélusca-Maïto <hermes.belusca-maito@reactos.org>
Reviewed-by: Stanislav Motylkov <x86corez@gmail.com>
harmonize the mixed usage of EINGABETASTE and ENTER
in favor of ENTER.
Allows us even to omit a linebreak in the format utility and
therefore get closer to en-US.rc
GCC8.4.0 dbg warned about:
[675/1849] Building RC object base/shell/cmd/CMakeFiles/cmd.dir/cmd.rc.obj
In file included from C:/ros/reactos/base/shell/cmd/cmd.rc:87:
C:/ros/reactos/base/shell/cmd/lang/tr-TR.rc:349:61: warning: backslash and newline separated by space
I guess somebody made the checks more strict recently,
because that bug was existing for longer already without
generating any warning for me.
- usetup: New bootsector page.
- shell32: Copy and paste, and moving elements.
Also, some strings related to the shutdown and logoff.
- Minor Spanish grammar fix - some female words and minor latin american typos.
- First revision of the .inf, that includes the translation of the Services,
audio, processors and other drivers and minor things.
Do not use custom alloc/free functions by default.
Do not free resources at process exit.
- You're doing it brick by brick while the OS & CRT do that with a bulldozer better than you do.
This properly strips spaces & dots at the end of the file.
Fixes the infinite loop with CreateProcess calling cmd over and over with e.g. 'cmd /c "some_script.bat "'
Uncovered by recent ShellExecuteEx tests
Dedicated to Katayama for the trigger & Hermès for the tests