about summary refs log tree commit diff stats
path: root/samples/lynx.bat
diff options
context:
space:
mode:
authorThomas E. Dickey <dickey@invisible-island.net>2018-03-21 16:20:42 +0000
committerThomas E. Dickey <dickey@invisible-island.net>2018-03-21 16:20:42 +0000
commit9432fa8a1a1a932811a63ffdb54064a53446ca83 (patch)
treeccde586a80f19923f242668fdd8a0a152e825dc7 /samples/lynx.bat
parentc838e830e4b14855f27dc7a166f0684af41bdd35 (diff)
downloadlynx-snapshots-9432fa8a1a1a932811a63ffdb54064a53446ca83.tar.gz
snapshot of project "lynx", label v2-8-9dev_16y
Diffstat (limited to 'samples/lynx.bat')
-rw-r--r--samples/lynx.bat35
1 files changed, 24 insertions, 11 deletions
diff --git a/samples/lynx.bat b/samples/lynx.bat
index 03f4a5db..417cd748 100644
--- a/samples/lynx.bat
+++ b/samples/lynx.bat
@@ -1,18 +1,31 @@
 @echo off

-@rem $LynxId: lynx.bat,v 1.6 2018/03/18 17:20:13 tom Exp $

-@rem Claudio Santambrogio

-@rem improved by loto1992@inbox.ru

+@rem $LynxId: lynx.bat,v 1.9 2018/03/21 16:10:36 tom Exp $

+@rem demonstrate lynx with color-style

 setlocal

 

-set TERM=vt100

-set HOME=%~dp0

+	set TERM=vt100

+rem Set HOME to make URLs in config work, though this prevents -trace

+	set HOME=%~dp0

+	set PATH=%HOME%;%PATH%

 

-rem  normally set, but just in case..

-if "x%TEMP%"=="x" set TEMP=%HOME%tmp

-mkdir "%TEMP%"

+rem We need a temporary directory

+	if not "x%LYNX_TEMP_SPACE%"=="x" goto :do_cfg

+	if "x%TEMP%"=="x"                set LYNX_TEMP_SPACE=%TEMP%

+	if not "x%TEMP%"=="x"            goto :do_cfg

+	if "x%TMP%"=="x"                 set LYNX_TEMP_SPACE=%TMP%

+	if not "x%TMP%"=="x"             goto :do_cfg

 

-set LYNX_CFG=%HOME%lynx-demo.cfg

-set LYNX_LSS=%HOME%lynx.lss

+	set LYNX_TEMP_SPACE=%HOMEDRIVE%%HOMEPATH%tmp

+	mkdir "%LYNX_TEMP_SPACE%"

+	if not errorlevel 0              goto :do_cfg

 

-"%HOME%lynx.exe" %1 %2 %3 %4 %5

+	echo Cannot make temp-directory

+	goto :eof

+

+:do_cfg

+	set LYNX_CFG_PATH=%HOME%

+	set LYNX_CFG=%HOME%lynx-demo.cfg

+	set LYNX_LSS=%HOME%lynx.lss

+

+	lynx.exe %1 %2 %3 %4 %5 %6 %7 %8 %9

 endlocal