Request dir tag

It would be very helpful if we had dir tag
this would eliminate need of telling if we are referring to file or directory

dir tag could format output in DarkSlateBlue and make sure that directory ends with "/" + use same font as file tag:

/example/dir/

What do you think?



P.S.
I wrote this (but longer) few minutes ago, where did my thread go?
 
darkshadow said:
Why would you reference directory structure ?
Code:
[color="Cyan"]/mad/ali[/color]


  • simple example:
  • copy /bla/bla/bla/ to /no/bla/bla/bla/
  • copy /bla/bla/bla to /no/bla/bla/bla
Which one is more descriptive?

Also fat is, I don't like referencing different things with same tag....
Using dir and file tags, would allow you to analyse content visually before you read it
 
simple example:
copy /bla/bla/bla/ to /no/bla/bla/bla/

Then you can use post formating options without any additional tags :),unless you are so lazy to move the mouse and do some clicks .
 
darkshadow said:
Then you can use post formating options without any additional tags :)

still ability to make directories mentioned in text formatted seems attractive to me....
Heck, we have lots of tags, that nobody use...

I sometimes write HOWTOS here, and I would appreciate, if I could format them easier....
You know writing howto takes quite some time...

If I can use tag, to make my howto more descriptive, and easier to read, what harm is there?
I could as well write unformatted flat blog, reader would understand in the end, but it would take him much more time.

If I can answer question with simple answer, that contains only directory, without explaining what this info means, if user looks at flat text, and can see:
* here author refers to file
* here author refers to directory
without reading entire blob, isn't that good?

I'm not asking for rewriting this forum in AJAX (I'd love that, it would bring so much speed [tested on my homepage, which doesn't seem to be ready in near future]


Anyway, let admins decide
 
It would make more work to write files with full paths, needing both dir and file tags. Why not just modify the file tag to use basename and dirname and do it automatically? Directory-only paths would have to end with a "/" to show the last part was a directory, but that's not a big deal.

I'm not sure about whether the feature is needed, but it wouldn't bother me if writing paths wasn't any harder.
 
wblock said:
It would make more work to write files with full paths, needing both dir and file tags.
No, you missed my point... If you refer to file, you use file tag
/etc/rc.conf

if you refer to directory you use dir tag
[dir]/usr/local/etc[dir] <- tailing / appended automatically (when necessary) ==> /usr/local/etc/

wblock said:
Why not just modify the file tag to use basename and dirname and do it automatically? Directory-only paths would have to end with a "/" to show the last part was a directory, but that's not a big deal.

file tag could be modified, to format in different color if tailing / is mentioned, but I think it's better to have separate tag
 
killasmurf86 said:
No, you missed my point... If you refer to file, you use file tag
/etc/rc.conf

if you refer to directory you use dir tag
[dir]/usr/local/etc[dir] <- tailing / appended automatically (when necessary) ==> /usr/local/etc/

That blue hardly looks any different than black text here. If this happens, a brighter color might be needed.

But let me ask a different question: what does the blue tell you that a trailing slash does not? The trailing slash is already a visual indicator that it's a directory.
 
wblock said:
That blue hardly looks any different than black text here. If this happens, a brighter color might be needed.

But let me ask a different question: what does the blue tell you that a trailing slash does not? The trailing slash is already a visual indicator that it's a directory.

blue is different than green (well maybe my blue color wasn't the best pick) ;) thus you might not see slash from 5 meters, but if you will know that where files are mentioned, and where directories are.
 
/usr/src/Makefile is a file, /usr/src/ is a directory. The [file] tag can fulfill that role, and quite a number of other roles (device names, variables, bits of code). We have enough tags already (and we certainly don't want a mess of colors everywhere), and it's not as if people are willing to invest any time in proper formatting or writing proper posts anyway with what we already have ... Don't need to look far for examples, I think.
 
FYI the Handbook also doesn't really make difference in style for files and dirs (although we distinguish it in the sgml sources). As has been said, if you refer to the directory, add the '/' at the end. The automagical addition of the slash at the end is impossible with the current tags anway as I understand it.
 
killasmurf86 said:
lol, true (almost, networks card devices doesn't have "Special file", AFAIK)
No, but sockets do.

More on topic, I try to keep this in mind myself. Use /some/directory/ with a trailing slash to indicate a directory and /some/file without the trailing slash to indicate a file.
 
Back
Top