Re: Autorun ability on cd?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On Wed, August 5, 2009 16:37, James B. Byrne wrote:
>
> On: Wed, 5 Aug 2009 10:15:47 -0400, Stephen Harris
> <lists@xxxxxxxxxx> wrote:
>>
>> Untested, and it depends very much on your shell, but create a
>> function
>>
>>   cdr()
>>   {
>>     cd $1 || exit
>>     if [ -x ./.myscript ]
>>     then
>>       ./.myscript
>>     fi
>>   }
>>

Works like a charm.

$ cd projects/proforma.git
  Deploy-V.01.01.01
* master

Many thanks for this.

Sincerely,

-- 
***          E-Mail is NOT a SECURE channel          ***
James B. Byrne                mailto:ByrneJB@xxxxxxxxxxxxx
Harte & Lyne Limited          http://www.harte-lyne.ca
9 Brockley Drive              vox: +1 905 561 1241
Hamilton, Ontario             fax: +1 905 561 0757
Canada  L8E 3C3

_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos

[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux