[OS X TeX] TeXcount Drop Scripts.

Herbert Schulz herbs at wideopenwest.com
Mon Mar 23 09:41:47 EDT 2009


On Mar 23, 2009, at 8:16 AM, Peter Dyballa wrote:

>
> Am 23.03.2009 um 14:01 schrieb Herbert Schulz:
>
>> (Also... can anyone with deeper knowledge about bash shell  
>> scripting than I have [that's a lot of folks on this list!] explain  
>> push/pop to me?)
>
>
> You probably mean pushd and popd?
>
> The former puts a directory on a stack. This top-most element  
> becomes now the current working directory. Pushd is in interactive  
> use preferred over cd because it does not clear the whole stack but  
> adds element after element on top.
>
> The latter pops (or pushes away) the top-most element off the  
> directories stack. After a popd command the current working  
> directory is changed to the new (elder) top-most element on the stack.
>
>
> In interactive use 'dirs' lists all the elements on the stack. The  
> command 'pushd <number>' puts the n-th element of these on top.  
> Similarly 'popd <number>' removes this n-th element without touching  
> the top-most one, i.e., without changing the current working  
> directory – at least when the number is greater than one!
>
> --
> Greetings
>
>  Pete
>
> The human brain operates at only 10% of its capacity. The rest is  
> overhead for the operating system.
>


Howdy,

Thank you Pete. Since I was only going one directory deep I originally  
got away with saving the pwd and cd'ing into that directory and the  
cd'ing back to the old pwd. I've changed that in the internal scripts  
for the Drop Scripts to pushd and popd since it is more elegant. The  
scripts on line are updated with those internal scripts.

Good Luck,

Herb Schulz
(herbs at wideopenwest dot com)






More information about the MacOSX-TeX mailing list