pas2js: fixed option --simpleserver and -d relative path

git-svn-id: trunk@49008 -
(cherry picked from commit 29dee4a0d3)
This commit is contained in:
Mattias Gaertner 2021-03-19 10:31:46 +00:00 committed by Florian Klämpfl
parent 6eaceb2f53
commit 2ccfde90d0

View File

@ -558,12 +558,13 @@ begin
S:=Checkoptions('shqd:ni:p:wP::cm:',['help','quiet','noindexpage','directory:','port:','indexpage:','watch','project::','config:','simpleserver','mimetypes:']);
if (S<>'') or HasOption('h','help') then
usage(S);
FServeOnly:=HasOption('s','serve-only');
FServeOnly:=HasOption('s','simpleserver');
Quiet:=HasOption('q','quiet');
Port:=StrToIntDef(GetOptionValue('p','port'),3000);
D:=GetOptionValue('d','directory');
if D='' then
D:=GetCurrentDir;
D:=ExpandFileName(D);
if HasOption('m','mimetypes') then
MimeTypesFile:=GetOptionValue('m','mimetypes');
if MimeTypesFile='' then