Open vanillajonathan opened 11 months ago
Sounds like an interesting suggestion... and it should be easy to implement. We like your first rendering with emoticons.
Before starting, few questions:
should we sort file names:
@startfiles
/c
/b
/a
@endfiles
How should we render this:
@startfiles
/.github
/src/example1.py
/tests/example_test.py
/src/example2.py
/README.md
/LICENSE
strange_file.txt
@endfiles
It probably should not sort the file names, I think it should use the same order as they are written, then it is up to the users to write them in his desired order if he want them sorted or not. On the other hand, maybe the implementation would be easier if it were sorted, then that would be fine too.
I don't know how files or directories that does not start with a slash should be rendered, but I think all files in the same directory should be rendered together in the same directory since directory names must be unique.
@startfiles
/src/example1.py
/tests/example_test.py
/src/example2.py
@endfiles
Would be rendered as:
📂 src/
📄 example1.py
📄 example2.py
📂 tests/
📄 example_test.py
Ok, thanks.
Another simple question: In your first example:
@startfiles
/.github
/src/example.py
/tests/example_test.py
/README.md
/LICENSE
@endfiles
.github
is displayed as a folder. But how do we know that it is a folder and not a simple file?
Maybe we should have:
@startfiles
/.github/
/src/example.py
/tests/example_test.py
/README.md
/LICENSE
@endfiles
Any though?
Good point! Yes, I agree it should end with a slash in order to be rendered as a folder.
There could also be different file icons rendered depending on the file extension.
It's really a pre-alpha version that does not work as specified yet.
But I wanted to let you know that some work have been started.
Thanks for suggestion and stay tuned :-)
We've made some progress :-)
Any though?
Icons are not perfect (especially the colors). Do you know any free svg files we could use for files and folder icons?
Here is a possible example:
There needs to be some space between the icon and the file name.
Bootstrap icons are available under the MIT License. https://icons.getbootstrap.com/?q=file- https://icons.getbootstrap.com/?q=folder-
Really love this as I need something like this for my documentation. do you think it's possible to add notes at some point? Would be really useful.
So with last snapshot, you can have this:
@startfiles
/.github/
/src/example.py
/src/iiimple1.py
/tests/example_test.py
/src/wwwmple2.py
/tests/v1/example_test.py
/README.md
/doc/foo/dummy.doc
<note>
this is a note
on two lines
</note>
/LICENSE
@endfiles
This is still an early version, we are not satisfied with the syntax. Any idea is welcome!
Hi,
A mean question will be:
Regards
Maybe each file could have a separate comment to the right of the file name. Example:
@startfiles
/.github # Contains GitHub-specific files such as CI
/src/example.py
/tests/example_test.py
/README.md # This is Markdown format
/LICENSE # Contains the license
@endfiles
is it possible to have multi color folders?
example for this code, the folder foo
and v1
has color yellow, and the rest still use blue.
Files and folders starting with a dot, example .github
(hidden) could be dimmed.
@sahyung:
is it possible to have multi color folders? example for this code, the folder
foo
andv1
has color yellow, and the rest still use blue.
Good request...
*
or descendant selector
or depth
...For a new enhancement... (and group of all new wanted features).
Regards, Th.
@vanillajonathan:
Files and folders starting with a dot, example
.github
(hidden) could be dimmed.
For a new enhancement... (and group of all new wanted features).
Regards, Th.
Any news? It would also be nice to be able to style for example
Looks like if I write following:
/tests/__init__.py
It doesn't render correctly
Hi @davide1995, and all,
It is due to the Creole management, see this funny example:
@startfiles
/tests/__init_file__.py
/tests/~__init_file__.py
/**creole_test**/~~wave~~
/**creole_test**/**bold**
/**creole_test**/""monospaced""
/**creole_test**/--stricken-out--
/**creole_test**/__underlined__
/**creole_test**/~__not underlined__
/**creole_test**/~~wave-underlined~~
/**creole_test**///not italics :)//
/**creole_html_test**/<b>bold
/**creole_html_test**/<i>italics
/**creole_html_test**/<font:monospaced>monospaced
/**creole_html_test**/<s>stroked
/**creole_html_test**/<u>underlined
/**creole_html_test**/<w>waved
/**creole_html_test**/<s:green>stroked
/**creole_html_test**/<u:red>underlined
/**creole_html_test**/<w:#0000FF>waved
/**creole_html_test**/<color:blue>Blue
/**creole_html_test**/<back:orange>Orange background
/**creole_html_test**/<size:20>big
@endfiles
Enjoy... :-) Regards.
Hello, I also try to put Archimate sprite and it is not working
Funny indeed :-) However, we have disabled creole in last snapshot for filenames (tell us if you would like to have creole except for underline) Hope this help!
Hi,
Ok: to disable all Creole temporary.
But perhaps it will be interesting to have commands to highlight some folder or file, why not with the HTML creole form (where you are sure that those folder or filename don't include this HTML form inside there names... ).
Regards, Th.
It could even use different icons for different file extensions.
Hi, If I cannot use Creole, HTML creole will be good. Style and icon use will be alternatives
Hi, Could you please add "common commands" like title, legend, caption, etc. ?
Hi, Is there a way to include remarks or notes about a particular file or directory in its vicinity?
Hi @MySpamKit
Is there a way to include remarks or notes about a particular file or directory in its vicinity?
Yes, currently only below a file (not for directory) you can see this:
Regards, Th.
Thank you :-)
To me what would be useful is to be able to connect individual tree entries to other graphs. Specifically, adding this dimension to component diagrams to see how application fits into filesystem is what I am trying to do now.
map {} seems to fit ok for this purpose, except can't find how to align key text.
Are themes not supported? I'm using plantuml-asl-1.2024.3 and
!theme crt-amber from https://raw.githubusercontent.com/plantuml/plantuml/master/themes
other diagrams are rendered in the specified theme, but if I try to do the same with directory listing, it's white background, blue folders, gray files.
Hello @AlexCzar,
[Just for traceability]
You are right, that is not yet implemented, as for regex
:
Awaiting style improvement, Regards, Th.
Is it possible to render them with Pandoc when embedding the code in markdown?
For examples I would like something like the following in a .md file
@startfiles
/.github
/src/example.py
/src/example1.py
/tests/example_test.py
/src/example2.py
/tests/v1/example_test.py
/README.md
/doc/foo/dummy.doc
/LICENSE
@endfiles
and call pandoc to render it
Hello @mredenti,
Is it possible to render them with Pandoc when embedding the code in markdown?
Yes you can, but that is not directly relevant of plantuml itself (and not a question here on plantuml/plantuml
repo.)!
For this reason:
pandoc plantuml filter
?Here are some first results, to test and analyse....:
Go to test and Enjoy, Regards, Th.
Hi,
the notes are currently not indented for nested empty directories, is this intended?
@startfiles
/.github/
<note>
this note should be for .github
</note>
/.github/template/
<note>
this note should be for the template folder and indented
</note>
/doc/
<note>
this is a note for /doc
</note>
/doc/foo/dummy.doc
<note>
this is a note
on two lines
</note>
/LICENSE
@endfiles
Hello @Mairu,
Currently only notes for file, not for folder, are available.
See the above remark:
Then for folder that will be now a wanted feature...
And on the same topic, see also an old issue on notes here:
Regards, Th.
Is your feature request related to a problem? Please describe. I want a directory listing.
Describe the solution you'd like
PlantUML should render this prettily!
or: