       Amadeus the great (command line) composer v1.0
                        Written by
             Paul Cartwright and Paul Hamer
                   (c) 26th July 1994



Introduction:


Bored of always typing in a tortuous command line in order to carry 
out a seemingly simple task?
	i.e.       cc myprog.c -lgem -mc68030 -o myprog.prg
	
	Or for fans of the internet:
		   lzh -x -r archive.lzh d:\in_here\

THEN READ ON:

	AMADEUS.TTP is the answer!
	
	It has improved MY productivity immensely; finishing jobs that 
	would normally take over a hour in only a few pico seconds!    
	 
	All you have to do is edit one (or maybe two to be flash) 
	files and true speed can be at your fingertips! 






Section One: The Program
	
	I have always wanted to be able to double-click on the icon of 
	an archive file and have it extract, without any aggro; 
	creating subdirectories, and put the output onto a sensible 
	place. However life is not so simple. 
	Each archive requires its own syntax, which I never am able to 
	remember first time, and the desktop I use is not good enough 
	to give even a simple "x" in front of the filename to the 
	archive.
	
	Also I enjoy using the atari's graphical environment for doing 
	complex file management tasks, why can't I simply compile a C 
	source file from a double click from the desktop? 
	 
	AMADEUS gives atari users this flexibility and power. If you 
	know beforehand what 1,2,or even 3 things you are likely to 
	want to do with a particular file type then you NEED AMADEUS!
	




Section Two: How it works
	AMADEUS.TTP takes a file to be worked on.
	It works out what kind of file it is then composes a command 
	line out of that file and any other characters, etc required. 
	Then it executes a program with this command line.
	
	AMADEUS.TTP requires to be in the same directory as 
	AMADEUS.INF which has the following syntax; In each line:
	
	.abc d:\myfolder\myarcer.ttp string comment1 ... commentn 
	
	where .abc is the file-type e.g. 
			.arc
			.lzh
			.c
			
	d:\myfolder\myarcer.ttp is the full path-name of the program 
	to be executed i.e.
		c:\archives\arc.ttp
		c:\archives\lzh.ttp
		d:\gnu.c\bin\gcc.ttp
		
	and string is the command line supplied to the program
		




Section Three: The Command Line

	
	the string (above) will be echoed to the command-line
	(i.e. the command-line will be the same as the string) except 
	for the following instances:
	
		%p         replaced with path of supplied file
				(including trailing backslash)
		
		
		%f	   replaced with filename of supplied file
		
		%.abc      replaced with filename of supplied file 
			except the file-extender replaced with "abc"
		
		%%		replaced by "%"
		
		_		(underscore)-replaced by a space
		
		%_		replaced by underscore!
		

	This syntax allows the production of fairly complex command 
	lines:
		eg
		%f_-o_%.tos will create the command line  
		"myfile.xxx -o myfile.tos"
		very handy for C hackers.
		
		or 
		-x_-r_%f_%p will create the command line
		"-x -r myarc.xxx a:\myfolder\dir\"
		very handy for unarcing stuff. 
		   




Section Four: Extras

		1.The program will change the working directory to be 
		the one from which the supplied file comes. This is 
		useful as some archives don't have such niceties, and 
		allows the string to be less complex in many cases.
		
		2.When executed AMADEUS.TTP checks the status of the 
		two shift keys (right and left). This allows AMADEUS
		to have more than one behaviour
		
			e.g.
			You may want sometimes to view the contents 
			of, rather than extract from an archive.
			
			or you might want sometimes to supply 
			different compiler options to your cc i.e. to 
			link in a maths or gem library, or output a 
			different kind of file
		
		The first time AMADEUS.TTP comes across a particular 
		file type in AMADEUS.INF corresponds to the default
		 command-line (the one used if no shift keys are held 
		 down)
		The second occurence of this extender corresponds to 
		the command-line to be used if the RIGHT-SHIFT key is 
		held down.
		And the third time corresponds to the command-line 
		used if the  LEFT-SHIFT key is held down.
		
		(See example AMADEUS.INF)
		




Section Five: Installing AMADEUS
                If your desktop supports "drag and drop" operations 
                then you can simply drag your chosen file to 
                AMADEUS.TTP, But for the ultimate in 
                user-friendliness, AMADEUS must run when any file (of 
                a valid type) is double-clicked on.
		In order to do this, you must inform your desktop to 
		pass these files to AMADEUS.TTP.
		
		Most desktops have an "install application" feature, 
		this allows a certain program to be run with 
		files of a particular type by double-clicking on the 
		icon of the file to be supplied to the program. In 
		this case the command line looks like:
			a:\myfile.abc
		It is necessary to "install as application" all the 
		file types that you want AMEDEUS to deal with.
		However some desktops e.g. MAGXDESK and the GEM 
		desktop limit the number of filetypes that can be 
		installed to one application.
		In this case it is necessary to manually edit the 
		DESKTOP.INF or MAGX.INF, file,  etc. 
		
		There is an easy way of doing this:
			You will have to translate this to the 
			particular desktop that you are using
			
			1. Highlight AMADEUS.TTP
			2. Select "Install Application"
			3. Enter a sample file-type as the extender
			4. save the desktop configuration (settings)
			5. Load the DESKTOP.INF, MAGX.INF, etc. into 
			your favourite text editor
			6. Find the line which mentions AMADEUS.TTP 
			and the sample file type
			7. Copy this line
			8. Paste it as may times as you like, 
			substituting another desired file-type with 
			the sample one.
			
			If this doesn't work (i.e. your desktops info 
			is not ASCII or it cannot accept more than a 
			certain number of file-types to be installed 
			for one particular application then you can't 
			use your desktop: Buy a new one!
			
			Don't forget to set up AMADEUS.INF by editing 
			it with your favourite text-editor.
				After the extender and path of the 
				program to be executed you can have as 
				many comments as you like on the 
				remainder of the line. So you won't 
				forget!



		 
Appendicies


One: Floppy based systems

	If you haven't got a hard drive, AMADEUS can still work for 
	you. i.e. to unarchive stuff you require a line in your 
	AMADEUS.INF something like:
		
		.arc b:\archives\arc.ttp x_%p%f
	
	Now your operating system should prompt you to insert disk B 
	in drive A, at which point you put in your utils disk. ARC.TTP 
	would be loaded from disk B then the operating sytem will 
	prompt you to insert disk A in drive A, insert the disk with 
	the archive on it (the first disk) to begin unarchiving

Two: Old TOS 
				
	If you have the misfortune to still be using an old version of 
	TOS. We feel for you. If AMADEUS.TTP will not work properly 
	under your old TOS, well- its time to move on up to MagiC, TOS 
	2.06, Geneva, or MultiTOS for instance. Also all 3rd party 
	replacement desktops (as far as I am aware) fix the parameter 
	passing bug of old TOS (including those in the public domain),
	installing one of these should allow AMADEUS to work on your 
	system. 

Three: Tips
	
	AMEDEUS can easily be configured to run different programs on 
	a particular file type when a certain SHIFT combination is held 
	down. This is useful:
		If you have two C compilers
		or more than one version of a particular archive util.	




			
Four: Disclaimer, Distribution, etc.

	This is FREEWARE; it can be copied freely
	so long as the files 
	AMEDEUS.TTP, AMMEDEUS.C, AMEDEUS.TXT, and AMEDEUS.INF
	are kept together, and such copying is not for profit. 
	For Atari ST computers these files cannot be modified 
	and any port to another machine must mention its origins
	in the documentation.
		
	
	We accept no responsibility for the behaviour or misbehaviour 
	of this software. It comes with absolutely NO warranty...
	...Use at your own risk.
	
	However if you feel you can suggest any additions, find any 
	bugs or have any comments to make, please address them to:
		
			Paul Hamer
			1, Kingsmead Road North
			Birkenhead
			Merseyside
			ENGLAND
			L43 6TB 
		   