Excerpts from Maxim Gonchar's message of 2014-04-18 10:00:59 +0200:
> for i in */; cd $i; echo "i am at $i"; prevd; end

yeah, that's what i usually do, but sometimes the inside of the loop works in
multiple directories, at which point it becomes more complex.

i also realized that i can use 
for i in */; pushd $i; echo "i am at $i"; popd; end
which should help if there is more stuff going on inside.
another option would be to save the starting directory and always cd to that
directory as a first step.

i wonder if that could be wrapped into a function...

greetings, martin.

-- 
eKita                   -   the online platform for your entire academic life
-- 
chief engineer                                                       eKita.co
pike programmer      pike.lysator.liu.se    caudium.net     societyserver.org
BLUG secretary                                                 beijinglug.org
foresight developer  foresightlinux.org                            realss.com
unix sysadmin
Martin Bähr          working in china        http://societyserver.org/mbaehr/

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Fish-users mailing list
Fish-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/fish-users

Reply via email to