Skip to content

Comment on Ask HN: Programming Without Files and Foldersparent

Comments

valtyOP

I'm trying to think of a middle-ground. Plain text and files are really great in so many ways. I think _folder hierarchies_ are the problem.

Maybe a virtual file-system...

With VS Code fuzzy filename search (CTRL-P) and project-wide text search (CTRL-SHIFT-F) you could probably get away with dumping all your files into a single directory. I find myself using these tools to navigate my projects more than the folder tree.

However, it makes sense to have things like web site routes match your FS structure...

Vite has this concept of path aliases[1]. So you can give a folder an alias like `$data`. If you want to change that folder's location in the hierarchy later, it's just a matter of moving the folder and updating the alias. So you could start with all your folders in the project root and worry about the folder structure later.

[1]: https://dev.to/tilly/aliasing-in-vite-w-typescript-1lfo

Using, eg. C, it's fairly simple to have minimal structure: you can have every .h and .c file in the top-level project directory if you want (and that used to be common in the 80s). Now, you'd normally have at least a "src", and maybe a separate "include" hierarchy, and maybe split things up further for different modules.

Java, OTOH, enforces a lot of directory structure. It's a bit of a nightmare to use without an IDE or a fuzzy-find for that reason.

A fuzzy-find system could be more-or-less viewed as a virtual filesystem?

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.