Get a directory list without symlinks

Q&A's, tips, howto's
Locked
Xixo
Posts: 2
Joined: Tue Nov 18, 2014 8:54 pm

Get a directory list without symlinks

Post by Xixo »

Hi all.
Probabily a simple problem for you (I hope!).
I'm tryng to get a list from directory() without symlinks.
I mean only folders and real files.
I look around with no luck.
Is it possible?
Thanks in advance for any help!

Xixo

Xixo
Posts: 2
Joined: Tue Nov 18, 2014 8:54 pm

Re: Get a directory list without symlinks

Post by Xixo »

Found:

http://www.newlisp.org/index.cgi?page=Code_Snippets

(define (link? path-name)
(= 0120000 (& (file-info path-name 1) 0120000)))

Sorry for the noise!

X.

Locked