cygnus - Open a Cygwin BASH window
%cygnus-bin-path - Cygwin BASH directory
%cygnus-hilight - Cygwin shell hilight enable flag
%cygnus-prompt - Cygwin shell prompt
Windows '95/'98/NT - win32 ONLY
cygnus
%cygnus-bin-path "path"
%cygnus-hilight [0|1]
%cygnus-prompt "hilightString"
cygnus creates an interactive BASH shell window within a MicroEmacs buffer window, providing a UNIX command line facility within the Microsoft Windows environment. This is a preferable environment to the MS-DOS shell and is certainly far more comfortable for those people familiar with UNIX.
Within the window BASH commands may be entered and executed, the results are shown in the window. Within the context of the BASH shell window then directory naming conforms to the cygwin standard conventions (as opposed to the Microsoft directory naming).
On running cygnus a new buffer is created called *cygnus* which contains the shell. Executing the command again creates a new shell window called *cygnus1*, and so on. If a cygwin window is killed off then the available window is used next time the command is run.
Additional controls are available within the shell window to control the editors interaction with the window. The operating mode is shown as a digit on the buffer mode line, this should typically show "3", which corresponds to F3. The operating modes are mapped to keys as follows:-
F2
F3
F4
F5
To exit the shell then end the shell session using "exit" or "C-d" as normal and then close the buffer. A short cut "C-c C-k" is available to kill off the pipe. However, it is not recommended that this method is used as it effectively performs a hard kill of the buffer and attached process
%cygnus-bin-path is a user defined variable that defines the file system location of the cygwin directory. This variable MUST be defined within the user start up script in order for the cygnus command to start the shell. With a default installation of cygwin then the settings are typically defined as:-
Release B19
set-variable %cygnus-bin-path "C:/Cygnus/B19/h-i386~1/bin"
Release B20
set-variable %cygnus-bin-path "c:/cygnus/cygwin-b20/H-i586-cygwin32/bin"
%cygnus-hilight is a boolean flag which controls how the cygnus command shell window is hilighted. This value MUST be defined within the user start up script prior to executing cygnus if hilighting is to be enabled; by default hilighting is disabled. A value of 1 enables shell hilighting i.e.
set-variable %cygnus-hilight 1
%cygnus-prompt is an optional variable that is used in conjunction with %cygnus-hilight, it defines the hilighting string identifying the prompt. This allows the prompt to be rendered with a different color. The default prompt is bash-2.01$ and may be hilighted using a definition:-
set-variable %cygnus-prompt "bash-2.01$"
The user typically overrides the prompt definition within the BASH startup file, a more appropriate definition of the prompt may be:-
set-variable %cygnus-prompt "^[a-z]*@[^>]*>"
The cygnus command uses the ipipe-shell-command(2) to manage the pipe between the editor and the bash shell. The window is controlled by the macro file hkcygnus.emf which controls the interaction with the shell.
The macro cygnus in hkcygnus.emf defines the parameter setup to connect to the cygwin bash shell (Version 19), installed in the default location c:/cygnus. If your installation of cygnus is in a different location then correct the macro to match your install location, preferably correct by creating a mycygnus.emf file in your user directory simply containing a re-defined cygnus macro.
If you have exported some of the cygwin environment variables in your autoexec.bat then you will have to figure out for yourself what variables macro cygnus needs to export - the current configuration is for a vanilla install.
The bash shell is executed with options i, for interactive shell and m to enable job control.
This configuration has only been tested on a Windows '98 installation, whether this works on NT and Windows '95 (OEM SR2) is unknown.
We have only been running "make" operations in the shell and do not know how the likes of "more", "man" or anything other terminal interaction works.
Tested Configurations
cygwin version B19.3 - this is the original "cygwin" distribution + the latest "coolview.tar.gz" patch.
cygwin version B20 - the latest cygwin distribution.
Break Key
Slow Response
You can see the start-up location in the top of the buffer when the shell is started.
Prompt at top of buffer
WinOldAp
Locked Input
ipipe-shell-command(2),
ishell(3).
Cygnus Win32 home sites www.cygnus.com and www.cygnus.co.uk
(c) Copyright JASSPA 1999
Last Modified: 1999/05/27
Generated On: 1999/12/01