FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Fedora User

 
 
LinkBack Thread Tools
 
Old 03-03-2010, 02:21 AM
Armelius Cameron
 
Default (OT) Generate Graphical Tree (SVG / PNG) of Directory Structure

Hello,
First, I apologize for the OT question, but I figure this list is one of the
best resources that may be able to answer this. I have attempted a Google
search for this, of course.

I am wondering if anyone knows any tool to generate a graphical representation
of directory structure as a tree. Directories would be a node, files would be
leaves. I know about the command line "tree". It's similar, but not exactly
what I need. It'd be nice to be able to rotate something like the output of
"tree" command line 90 degree, so that the siblings are on the same horizontal
level. Also, preferably the output is in SVG, so I can edit it using e.g.
Inkscape. But if not, I guess other formal (i.e. PNG, PS) is a possibility
too.

I know about Graphviz. So if I can't find anything I guess I can try to do this
myself and code up something. I just didn't want to do the work if something
is already out there . If there are other tools similar to Graphviz (maybe
something simpler), I'd like to hear about it too.

Any help ?

Thanks in advance.
AC
--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
 
Old 03-03-2010, 05:32 AM
Roger
 
Default (OT) Generate Graphical Tree (SVG / PNG) of Directory Structure

On 03/03/2010 02:21 PM, Armelius Cameron wrote:
> Hello,
> First, I apologize for the OT question, but I figure this list is one of the
> best resources that may be able to answer this. I have attempted a Google
> search for this, of course.
>
> I am wondering if anyone knows any tool to generate a graphical representation
> of directory structure as a tree. Directories would be a node, files would be
> leaves. I know about the command line "tree". It's similar, but not exactly
> what I need. It'd be nice to be able to rotate something like the output of
> "tree" command line 90 degree, so that the siblings are on the same horizontal
> level. Also, preferably the output is in SVG, so I can edit it using e.g.
> Inkscape. But if not, I guess other formal (i.e. PNG, PS) is a possibility
> too.
>
> I know about Graphviz. So if I can't find anything I guess I can try to do this
> myself and code up something. I just didn't want to do the work if something
> is already out there . If there are other tools similar to Graphviz (maybe
> something simpler), I'd like to hear about it too.
>
> Any help ?
>
> Thanks in advance.
> AC
>

why not find a way to represent a tree with branchess and leaves for
each file in blender3d
Then you could rotate it 360 degrees in each direction.
Roger

--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
 
Old 03-03-2010, 01:50 PM
NoSpaze
 
Default (OT) Generate Graphical Tree (SVG / PNG) of Directory Structure

Am Dienstag, den 02.03.2010, 22:21 -0500 schrieb Armelius Cameron:
> I am wondering if anyone knows any tool to generate a graphical representation
> of directory structure as a tree. Directories would be a node, files would be
> leaves. I know about the command line "tree". It's similar, but not exactly
> what I need. It'd be nice to be able to rotate something like the output of
> "tree" command line 90 degree, so that the siblings are on the same horizontal
> level. Also, preferably the output is in SVG, so I can edit it using e.g.
> Inkscape. But if not, I guess other formal (i.e. PNG, PS) is a possibility
> too.
>
> I know about Graphviz. So if I can't find anything I guess I can try to do this
> myself and code up something. I just didn't want to do the work if something
> is already out there . If there are other tools similar to Graphviz (maybe
> something simpler), I'd like to hear about it too.

Maybe this graphviz I used once will help, it generates a PNG. I used
some recursion, but no clue about doing it with just one command (find,
tree, may..be?)
---
#!/bin/bash
function recurse () {
SUBS=$(find $1 -mindepth 1 -maxdepth 1 -type d)
for a in $SUBS
do
echo ""$1" -> "$a";" >> $DOTFILE
recurse $a
done
}
DOTFILE=$(mktemp)
export IFS=$'
'
echo "digraph unix {" > $DOTFILE
echo "node [color=lightblue2, style=filled];" >> $DOTFILE
recurse $1
echo "}" >> $DOTFILE
dot -Tpng $DOTFILE > dirs.png
eog dirs.png &

---
Call it with drawrecurse.bash /home/myuser/mytree. You can modify it in
many ways, and change graphviz options to get your desired output.

Greets!
----------------------------------------------
Rodolfo Alcazar - rodolfo.alcazar@padep.org.bo
otbits.blogspot.com / counter.li.org: #367962
----------------------------------------------
/* I can C clearly now */


--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
 
Old 03-03-2010, 01:50 PM
NoSpaze
 
Default (OT) Generate Graphical Tree (SVG / PNG) of Directory Structure

Am Dienstag, den 02.03.2010, 22:21 -0500 schrieb Armelius Cameron:
> I am wondering if anyone knows any tool to generate a graphical representation
> of directory structure as a tree. Directories would be a node, files would be
> leaves. I know about the command line "tree". It's similar, but not exactly
> what I need. It'd be nice to be able to rotate something like the output of
> "tree" command line 90 degree, so that the siblings are on the same horizontal
> level. Also, preferably the output is in SVG, so I can edit it using e.g.
> Inkscape. But if not, I guess other formal (i.e. PNG, PS) is a possibility
> too.
>
> I know about Graphviz. So if I can't find anything I guess I can try to do this
> myself and code up something. I just didn't want to do the work if something
> is already out there . If there are other tools similar to Graphviz (maybe
> something simpler), I'd like to hear about it too.

Maybe this graphviz I used once will help, it generates a PNG. I used
some recursion, but no clue about doing it with just one command (find,
tree, may..be?)
---
#!/bin/bash
function recurse () {
SUBS=$(find $1 -mindepth 1 -maxdepth 1 -type d)
for a in $SUBS
do
echo ""$1" -> "$a";" >> $DOTFILE
recurse $a
done
}
DOTFILE=$(mktemp)
export IFS=$'
'
echo "digraph unix {" > $DOTFILE
echo "node [color=lightblue2, style=filled];" >> $DOTFILE
recurse $1
echo "}" >> $DOTFILE
dot -Tpng $DOTFILE > dirs.png
eog dirs.png &

---
Call it with drawrecurse.bash /home/myuser/mytree. You can modify it in
many ways, and change graphviz options to get your desired output.

Greets!
----------------------------------------------
Rodolfo Alcazar - rodolfo.alcazar@padep.org.bo
otbits.blogspot.com / counter.li.org: #367962
----------------------------------------------
/* I can C clearly now */


--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
 
Old 03-03-2010, 11:14 PM
Armelius Cameron
 
Default (OT) Generate Graphical Tree (SVG / PNG) of Directory Structure

On Wednesday 03 March 2010 09:50:49 am NoSpaze wrote:
> Am Dienstag, den 02.03.2010, 22:21 -0500 schrieb Armelius Cameron:
>
> Maybe this graphviz I used once will help, it generates a PNG. I used
> some recursion, but no clue about doing it with just one command (find,
> tree, may..be?)
> ---

Thanks, this is close enough to what I needed, I was able to modify it to get
what I want, and generated SVG file too.

Thanks again.
AC
--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
 

Thread Tools




All times are GMT. The time now is 09:35 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org