X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:date:from:to:subject:message-id:references :mime-version:content-type:in-reply-to; q=dns; s=default; b=afEw pHv7GBFR7Zs5qo9fssv/OVrcY6BN/ObYw6Wk3hP0lFcCkD1stD2CNzUaZ36SuHwH 2VirklF0QolQAkXEfg3o0Kl8Y2vq6ucAred0w2ldeapba5+3EjCV2TTnS4lFlr+4 BrxwkmpVAg6zKfDdcfVVvEZUhbFbP12/yN/etBk= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:date:from:to:subject:message-id:references :mime-version:content-type:in-reply-to; s=default; bh=0p81cKhPa3 vcpRtOauUFJjj1Ges=; b=RMFOqCe3IdqL/Zxpii2NGLUB8Z0tGPFMhbJeESrjz4 eYh1/J5cPbQDSnMsP8Xkc3ymBkov8rltSfXskWxIkWNWG3/tueeNuigD7s0Cb50C NEcu9qa6zosr4UgRbuTP8orRSZqlc4pqY13U+RDqHdgWcWj226LVUYk/I9p8EHlg w= 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 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-1.8 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mail.spocom.com Date: Tue, 4 Feb 2014 12:50:41 -0800 From: Gary Johnson To: cygwin AT cygwin DOT com Subject: Re: Newbie Questions Message-ID: <20140204205041.GA16017@phoenix> Mail-Followup-To: cygwin AT cygwin DOT com References: <1898639722 DOT 6893470 DOT 1391541591920 DOT JavaMail DOT root AT ptd DOT net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1898639722.6893470.1391541591920.JavaMail.root@ptd.net> User-Agent: Mutt/1.5.20 (2009-06-14) X-IsSubscribed: yes On 2014-02-04, mrushton wrote: > I am loving Cygwin. > > I have been reading the manuals and documentation and have some > newbie questions. These are all general Unix/Linux questions, not specific to Cygwin, and are therefor not appropriate for discussion on the cygwin list. That said, I don't like dusting people off, so... > 1) When I go to execute a script, do I just type the name of it > or do i have to do a ./NameOfScript ? If the command is not specified by a path name, and if the shell doesn't find a built-in command, alias or function that matches the command name, it searches PATH for a file of that name. PATH does not normally contain "." and should not, for security reasons. Therefore, if you wish the execute a script in the current directory, and the current directory is not in your PATH, you have to specify the path to the script. > 2) I am trying to do an Alias of the Clear Command ... in my > bashrc I has an alias for clear to do a printf "\033c". Well > it does not seem to work from my scripts, but works from shell > prompt. > > Is this a path issue ? No. Aliases are not exported and hence do not appear in the environment of commands. > 3) I am still trying to figure out how to open a termial window > and have a menu script always run. > > Should I put this in my .profile or is there a better way to > do this ? I'm not sure you should do this at all, but if you want to try such a thing for a while, put it in your ~/.bashrc and execute it only if ~/.bashrc is sourced from an interactive shell. Some people determine this by checking if $PS1 is set while others check for the presence of "i" in $-. All of these questions are answered in the man page for bash, or whatever shell you are using. If you don't want to read the whole thing, just search for keywords from your questions. If you have further questions, you will have to find a different forum/list in which to ask them. Regards, Gary -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple