Page 1 of 1

QDOS and Toolkit II syntax

Posted: Thu Jul 09, 2020 3:06 am
by lowrybt
Hello,
Two novice queries....

1. Is there a command for redirecting calls to flpX_ to flpY_?

2. Is there a command or routine in QDOS that facilities finding and replacing specific code in basic files? For example, find and replace all instances of, say, PROG_USE?

Thanks, Tom

Re: QDOS and Toolkit II syntax

Posted: Thu Jul 09, 2020 10:52 am
by NormanDunbar
Hi Tom,

A1. Not that I am aware of, sorry.

A2. Do you have the C68 installation? If not, get it from Dilwyn's fine web site. Once you have it you can "redirect" flp1_ to flp2_ as follows:

Code: Select all

ex win1_c68_sed; '-g s/flp1_/flp2_/ input_file_name >output_file_name'
The docs for C68 explain all the options available in SED. For the substitute command, s, it is s/existing_text/replacement_text/. Output is normally to the screen hence the need to redirect to a desired output file. The input file will not be changed.

Alternatively, any text editor such as QED has the ability to search and replace.


HTH

Cheers,
Norm.

Re: QDOS and Toolkit II syntax

Posted: Thu Jul 09, 2020 11:26 pm
by ql_freak
lowrybt wrote:1. Is there a command for redirecting calls to flpX_ to flpY_?
Unfortunately AFAIK not. You can redirect MDV to e.g. FLP (MDV_USE, there is also FLP_USE and WIN_USE, and ...), but not the numbers (every directory device driver supports up to 8 drives).

But there is the REDIRECT device from Phil Borman which allows to redirect files to other files (similar as symbolic links in Unix). You can find it as redir.zip on Dilwyns Software Download page, look for redir.zip. Other useful device driver from Phil is the PTH device which allows a search path (similar as PATH on Windows, UNIX, ...) for files. Last but not least, if you have (I think) QPac2 (or of course QPC2) there should be the DEV device, which allows redirections.