Bug #223
Unix: Tilde expansion issues
Description
First, assuming of course the "Open Console" button has
been moved from the tilde key, pressing Shift+` still
results in the ` character being typed. Easily fixed in
dd_input.c (change line 150 from:)
/* 90 */ 'z', '{', '|', '}', 0, 0, 0, 'A',
'B', 'C',
to:
/* 90 */ 'z', '{', '|', '}', 0, 0, '~', 'A',
'B', 'C',
Second, with that fix made, typing something like:
playdemo ~/.doomsday/jdoom/demo/somedemo.cdm
won't work, because it appears the Dir_ExpandHome (or
Dir_IsValid which in turn calls Dir_ExpandHome)
function never gets called from whichever function it
is that handles playdemo.
(Using -playdemo ~/path/to/wherever on the command line
will work, but that's because the shell expands the
tilde before Doomsday ever sees it.)
Labels: Console
History
#1 Updated by danij almost 16 years ago
After some initial investigation it would appear that the problem mentioned in this report is merely the tip of the iceberg.
For starters, there is a fixed maximum length of filepaths in Doomsday (255 characters).
I think it would make sense to re-implement all filepaths used throughout the engine as ddstrings and then integrate tilde expansion into the virtual directory itself (it could be treated similar to '}' expansion of the Doomsday basepath).
#2 Updated by skyjake almost 16 years ago
Replacing filename_t with a ddstring-based implementation would be great, although such a big change that it should wait for Beta 7 at least.
#3 Updated by danij almost 16 years ago
Absolutely, I wouldn't dream of touching this now that we are so close to releasing beta6.
#4 Updated by eunbolt over 14 years ago
Has this bug been fixed?
#5 Updated by skyjake over 12 years ago
Typing ~ in the console has been fixed for 1.9.8.