X-Recipient: archive-cygwin AT delorie DOT com X-Spam-Check-By: sourceware.org Message-ID: <47D9353C.1030304@alice.it> Date: Thu, 13 Mar 2008 15:07:56 +0100 From: Angelo Graziosi User-Agent: Thunderbird 2.0.0.12 (Windows/20080213) MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: Re: On Bash options Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Eric Blake wrote: > Why execute bash, just to exec urxvt, which in turn executes another > instance of bash? Why not just put urxvt as the shortcut target > instead, using ~/.Xdefaults to control everything rather than needing > bash to set it up? Eric, For the sake of completeness the 'start_urxvt.sh' (located in /usr/local/bin) is ---------------------------------------------- #!/bin/bash export DISPLAY=:0 export XAPPLRESDIR=/usr/X11R6/lib/X11/app-defaults export XCMSDB=/usr/X11R6/lib/X11/Xcms.txt export XKEYSYMDB=/usr/X11R6/lib/X11/XKeysymDB export XNLSPATH=/usr/X11R6/lib/X11/locale start_XWin() { # Cleanup from last run. rm -rf /tmp/.X11-unix XWin -multiwindow -clipboard -silent-dup-error +bs & } /usr/bin/checkX || start_XWin exec /usr/bin/urxvt ---------------------------------------------- and the link on the desktop is: C:\cygwin\bin\run.exe bash --login -c start_urxvt.sh The problem I have tried to solve is: How to start an urxvt console [1] from a link on desktop, starting also the X server if it is not running. So what would be the best manner (including sourcing ~/.bash* so that the prompt, aliases etc. are OK)? What do you suggest? Perhaps the best thing is to add the solution to the Cygwin FAQ/HowTo. In any case your detailed explanation is better than an high level lesson! Many thanks, Angelo. --- [1] More generally, the problem to solve is: How to start an X application (Emacs, XFig,...) and/or the X server (if it is not running) with a link on desktop. ___ Facesti come quei che va di notte, che porta il lume dietro e se' non giova, ma dopo se' fa le persone dotte. . DANTE, Purgatorio, xxii 67-69 -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/