home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.sys.hp48
- Path: sparky!uunet!gatech!concert!seq!eldi.epfl.CH!COHEN_LA
- From: COHEN_LA@eldi.epfl.CH ((DANIEL COHEN-LAROQUE - CALL ME DAN -))
- Subject: Tree
- Message-ID: <920909181447.286@sic.epfl.ch>
- Sender: daemon@seq.uncwil.edu (Admin)
- Organization: UNCW news/mail gateway service
- Date: Wed, 9 Sep 1992 17:14:47 GMT
- Lines: 48
-
- BEGIN_DOC tree.doc
- 09.09.1992
-
- Hi all!
- Here is a small routine which recursively scans your HOMEDIR
- to see how it is made.
- The inspiration comes from Eric Davis (see on horn1), but
- this routine is quicker.
- Put it in the home directory ***name it TREE***
- and execute it (be sure the user flag 1 is cleared --> 1 CF )
-
- P.S. You can scroll the string with my program called scrn_v2.0
- available at comp.sources.hp48
-
-
- Prog. TREE
- ChkS #F4BAh
- Bytes 264.5
-
- END_DOC
-
- BEGIN_SRC tree
- %%HP: T(3)A(R)F(.);
- \<<
- IF 1 FC?
- THEN 1 SF "HOME
- "
- 0 TREE 1 CF
- ELSE EVAL 15
- TVARS \-> \165 $
- \<<
- IF $ { } SAME
- THEN UPDIR
- '\165' 5 STO-
- ELSE '\165' 5
- STO+ 1 $ SIZE
- FOR i $ i
- GET
- " "
- 1 \165 SUB OVER + "
- "
- + \165 ROT TREE +
- NEXT
- END
- \>>
- END
- \>>
- END_SRC
-