114
submitted 1 day ago* (last edited 1 day ago) by underscores@lemmy.zip to c/linux@lemmy.ml

I realized I always make a source folder under home and then subfolders named after programming languages to organize projects but then I realized I somehow had my own convention for how to store my source code and I have no idea where I got it from

Then I thought. what about other Linux users ?

What sorts of conventions do you have that pertains to folder structure in Linux ?

you are viewing a single comment's thread
view the rest of the comments
[-] Dave@lemmy.nz 27 points 1 day ago

Multiple people in this topic say they organise in directories for different programming languages, something I have never considered and I find it to be an odd way of organising for some reason I can't explain.

Where do you put a project with a Javascript frontend and a Python backend?

[-] Quibblekrust@thelemmy.club 4 points 17 hours ago

In a folder called javpy, of course!

[-] Starfighter@discuss.tchncs.de 3 points 22 hours ago* (last edited 22 hours ago)

Since projects of the same language often use the same tooling this makes it easier to clean up the whole directory by running something like this:

for d in ./*/ ; do (cd "$d" && somecommand); done

somecommand could be cargo clean if you're in the Rust directory for example.

[-] underscores@lemmy.zip 6 points 1 day ago

for me I consider that a web project so it goes into the typescript folder, if it's backend only then python

[-] Dave@lemmy.nz 10 points 1 day ago* (last edited 1 day ago)

Why group it into language instead of say a 'web' directory or 'android'/'mobile'?

I'm just curious, I am more of a 'throw everything in one directory and home I remember what I'm looking for' sort of organiser.

[-] underscores@lemmy.zip 3 points 20 hours ago

for me the project exists because I thought "id like to play with today" but not necessarily "I want to make a project"

[-] GreyCat@lemmy.world 5 points 1 day ago

Honestly it's a pretty good way of compartmentalizing projects in your mind.
You usually remember pretty well what language your wrote a project in.
And if you want to find a project again you just have to look in that language's directory.

Second advantage is that if there's a language you only fucked around a little for fun, it doesn't clutter the directories of your most used languages.

[-] Dave@lemmy.nz 3 points 1 day ago

Yeah that's a pretty good argument for it.

[-] vandsjov@feddit.dk 3 points 1 day ago

I agree, just have it by project. Otherwise I might have to look in different folders to find something. And what does it add, that something is grouped by language?

this post was submitted on 09 Dec 2025
114 points (100.0% liked)

Linux

60103 readers
666 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 6 years ago
MODERATORS