1. Not everything has an associated LSP. Sometimes a good filename is all you got to work with. 2. Sometimes you don't know what you are looking for before you actually find it. 3. Structure is knowledge too. Why separate functions in different files? Why not have 1 single file with your entire program? 4. Programming is sometimes very transversal. You need to add a bit to about 4 different classes/structs/files. File switching can be more common than actually typing in certain problems. 5. Many file trees provide additional info like git state, that may help either your analysis or your elderly man memory. Add this all up and most people find having the file tree up more useful than not having it up.
@2Fast4Youtube6 ай бұрын
I thought you were actually listing reasons to NOT use a filetree, since these problem can easily be solved, and is even better with a file search or a file grep for an idea that you may have of how the line of code looks like. (You can even do a git state search, or there is many git commands) I do have a reason for using a filetree. Is so that the first time that I open I project, I can have an idea of how the codebase structure looks like, where and how is everything organized. But yeah, once I have that knowledge, I don't need to open the filetree ever again
@rafaelbordoni5166 ай бұрын
I think you're confusing a file explorer with a file tree, you don't need this information taking up space all the time on the screen. Default neovim already comes with a file explorer, just do :Explore or :E. Won't really work as a file tree as it won't show structure of what's inside each directory, but then again an explorer solves all of these things you listed without taking up space on the screen all the time.
@MrWillooo6 ай бұрын
@rodrigoserafim8834 everything about your comment relates 1:1 with a misconception about how a workflow in neovim works. Did you ever try it?
@AMacedoP6 ай бұрын
I like to have the file tree open so my code is centered in the screen
@RenderingUser6 ай бұрын
the only correct opinion
@scben6 ай бұрын
i'm pretty sure there is a plugin for that
@felipemagrassi93526 ай бұрын
folke/zen-mode.nvim :)
@jearsh6 ай бұрын
lol. this is the definition of using the wrong tool for the job
@Mystic9986 ай бұрын
This basically. I could just center the text editor bit, but I might as well have something at least marginally useful on the left instead of blank space, and the file tree is a fine default choice.
@taylorallred62086 ай бұрын
The same reason I use a mini map in a video game. Gives me a lay of the land and the greater context of what I’m working in.
@Streetlolz6 ай бұрын
To have code more centered also its way easier to glance at the folder structure to figure out how the project is laid out
@guyonlead6 ай бұрын
Having a file tree is a mini map to a project. Typically I only using it while I am create a project from scratch and on the other side of the coin I'll have it open for the sake of me juggling different projects at a time.
@brianviktor82126 ай бұрын
It allows me to see the file structure at all times, and allows me to optimize the structuring on an continuous decision and inspiration basis. Seeing it makes that process much easier.
@Strammeiche6 ай бұрын
When I know the project I don't need the file tree, when I first open a project I like to look at the files to get a general overview and see things I may not directly come across. There is also a thought behind the file/directory structure that somehow relates to the business cases. Taking a closer look at that helps me getting to know the project better. Also I am someone who likes to look at every setting option so I also like to look at the files flying around (at least getting an overview)
@night_h4nter6 ай бұрын
that's if you do know what you're looking for. i usually don't, so i usually have it available. also creating files, moving them around, etc
@drunkenfarmer25136 ай бұрын
Because when you arrive in a project with 1000s files without knowing any name of classes you can't search for names you don't even know. Not everyone works on small CLI tools. Try navigating a project with 100s of folders with subfolders in a terminal without knowing any of them lmao
@Ivan-Bagrintsev6 ай бұрын
You basically gave the example of where terminal is better than GUI. If you have thousands of files in hundreds of directories you would never want to look through them using GUI
@drunkenfarmer25136 ай бұрын
@agrintsev Terminal is much better if you have an idea of the project, otherwise I think you need a first look, but to each there own. A 2 minutes look to understand the structure instead of writing names randomly until you find something saves lots of time
@phitc42426 ай бұрын
if I open the source for a large project for the first time, I usually start grepping for the entry point. then I work my way through the content (I see in the files duh) and grep the shit out of it. who bothers about filenames, anyways?
@drunkenfarmer25136 ай бұрын
@@phitc4242 entry point doesnt do anything in some projects, when you need to enter a spring project good luck finding anything relevant in the entry point lmao
@drunkenfarmer25136 ай бұрын
@@phitc4242 sorry but you wont find anything in the entry point of some projects
@Jiftoo6 ай бұрын
it's easier to keep the file tree open than to remember the file names in a project when I want to hop around
@leonss23566 ай бұрын
if I'm looking for something specific I use fuzzy finder/telescope, but I use a file tree when I don't know the codebase to quickly figure out what even is in it and to get the gist of the hierarchy and how source files relate with eachother, also because I hate when my code isn't at the center of my screen.
@sacredgeometry6 ай бұрын
1:05 How about knowing how the projects are structured and where you should be adding code?
@hamzarashid75796 ай бұрын
I used to have an open file explore on every single project but when I got into neovim the fuzzy finder change my life. I completely agree that using file explore and searching for files manually is just dumb, just use the fuzzy finder. It's gonna make your life alot easier.
@tofonofo46066 ай бұрын
DOS mentioned. Lets go. FLIP IS A WIZARD
@askholia6 ай бұрын
There is a 'Control Center' mentality in IDE's that has spread to all the VS users. The thing no one is saying is that this mentality and file trees make us feel both anchored and safe. The unconscious (and irrational) fear is that we will lose the thread of our code base if we don't have a mini-map at all times. This is a naive and young coder mentality - one I have had to disabuse myself of.
@Drag0ny6 ай бұрын
This argument applies to code, but many of my projects also have numerous assets (images, videos, etc). Files trees really help with those.
@somnolence53396 ай бұрын
For frontend projects file trees usually match routing, and at the end the common actions such as add/list/delete etc result in reuse of file names.. So you can have /admin/manage/users/list.ts Not only file tree is necessary then, but IDE feature that syncs file tree with currently open file.
@SmirkInvestigator6 ай бұрын
Yeah, I use the file tree for a couple reasons. The repo has a common file structure and looking at it can get a feel of the scope of the project. If I’m trying a new IDE or VIM setup and am too tired to figure out how to config the LSP
@amineabdz6 ай бұрын
It gives a good idea of the general scale and structure of the project, also it's literally the most common way to navigate files ever, I understand it might not be the most efficient when working on a project, but it needs 0 configuration and is intuitive to even the most illiterate computer user.
@soppaism6 ай бұрын
When looking for something you're not sure if it even exists.
@denimunjas68316 ай бұрын
I mostly use the file tree side panel on the left to center the text editor a little bit to the right. Wide monitor hurts my neck to keep looking left 😄 Jokes aside, sometimes glancing at the folder structure makes it easier to grok its architecture at a high level. Also LSPs for Python kind of suck. I consent, python is very dynamic, etc. but this means there are cases where I'll go for the file tree ¯\_(ツ)_/¯ Btw, folder is better than directory just because it's much easier to say and type 😄
@dyto22876 ай бұрын
Using File Tree is more efficient same as Search Trees are computing. Searching in flat list is bonkers.
@Kane01236 ай бұрын
I program C# so everything goes into Program.cs No point having folder visibility for a single file 🤷♂️
@besknighter6 ай бұрын
I don't keep the file tree open. But I from time to time (specially when I'm new to a project) will use it. It's like looking into a map of a city you are trying to familiarize yourself with. Pretty useful when you know nothing and want to get around. Less so when you know where everything is and the best way to get there from the top of your head.
@johnjeralddechavez48136 ай бұрын
To avoid neck pain
@m2x076 ай бұрын
File-trees are like mini-map to our project, as said in some other comments. Of course i don't have it open all the time, but definitely gives a good idea of where everything is when deleting/adding new file/s
@karan_hiremath6 ай бұрын
well when directory structure does matter for processing through files, then I find it useful to have some sort of file tree which shows how things are structured and how to parse the directory one example - we have an s3 bucket which has backups of logs from kafka. i want to write something which parses those backups and pulls records associated with a fraudulent user into a separate file. I want to create a temp file tree locally which is synced to match the structure of the s3 bucket so I can have it just crawl the S3 folder structure and then parse each chunk within the folders and then write out the filtered data to the temp directory. then ill probably load that data tar -czvf'ed into another s3 bucket and maybe eventually also load the data into a special schema in our DWH or ES cluster or something. end goal would be to have some fraud prevention models trained on this data
@dezly-macauley6 ай бұрын
Telescope + oil.nvim = Navigation bliss
@SergiobgEngineer6 ай бұрын
There's a reason why people name folders and create the structure of the project instead of just placing all the files in the same location. There's a lot of information there. You'll see that open source projects even go as far as to let you know what the structure is and what you should expect to find inside the said folders. Now, you might want to ignore all of that information. That's on you. But you can't say there's no information to be acquired there.
@firesennin16906 ай бұрын
If you are working on a small screen it makes sense to close the file tree or if needed swap for something else. On a big screen there is no reason, the whole idea that it will distract you is just socially accepted skill issue. inferring context from information is just part of reading. Not everyone has the goal to fill the monitor with background color.
@fuzzy-026 ай бұрын
Why not
@ChrisHaupt6 ай бұрын
What if someone sends you a file or you download a file from somewhere that needs to go in your codebase. Being able to drag and drop into the VSCode file tree from that download location is way faster and less finnicky than trying to do some CLI ninjitsu to get it from one deeply nested directory to another.
@oretepavcevic20726 ай бұрын
When you have an @ folder in your src from which you export all your components, hooks etc. (so that you only use abdolute imports), going to definition means you end up in a file of that folder 😬
@fuzzy-026 ай бұрын
Game options > gameplay > disable minimap ON
@psyqwix6 ай бұрын
I get the doubling down on the "Folders". I grew up with MSDOS and to me everything was programs and executables, when everyone started calling these things "apps" I was not impressed.
@squidwurrd6 ай бұрын
Prime has never written wordpress
@Mihaugoku6 ай бұрын
for me it's just that i'm so used to having a file tree that not having it feels odd and it bothers me.
@gammalgris24976 ай бұрын
In some cases going through the code doesn't work that easily (e.g. when an interface is used instead of an actual implementation and it's not directly apparent which implementation is used or reflection mechanisms are used intensively). But then the file tree won't help either. Such and other runtime behaviour is hard to retrace in a large code base. Parts are hidden or even spread among code and configuration files. Then you are forced to debug until you identify what happens at which place.
@JoshPeterson6 ай бұрын
Folder is easier to say than directory. I use Telescope to navigate inside my cwd, but I use Ranger as a Neovim plugin primarily to search in other directories. I'm sure I could get there faster if I fzf'd, but I've found fzf works better when you're in a smaller subdirectory. If you're in your home folder, it's virtually impossible to find anything. I'm sure there's a way to do it better in the home directory and I just haven't found it yet. I just like the look and feel of ranger though and I've only been using it for about a week now *Notice how many times I said directory 😂
@natescode6 ай бұрын
I struggle with "L" so directory for me 😂
@JT-mr3db6 ай бұрын
Mostly agree. In every day development it's not that useful to navigate via file tree. You are usually interested in finding uses or a specific function etc. Some frameworks however place great importance on the folder structure and you can learn a lot by visually inspecting it. Not really a game changing usage of file trees but still handy.
@Paulo5946 ай бұрын
I found a middle ground by moving the file tree and etc to the right, if I dont need I just hide it, but otherwise it also does not get in the way of the code. My vision gets focused away from it and in the code AND I can mess around with its size to see the full file name without messing the code. Im been learning vim motions and I’ve liked the file traversal so far, but I still think the whole setup and usage to be too burdensome. Still have a ways to go
@jearsh6 ай бұрын
the concept of precision and actually knowing things is lost to newer developers. if i know what i want, i don't want to step thru a bunch of levels in a tree just to get to it.
@fminus38636 ай бұрын
Only times i use it is either i'm creating new files so it's a chance to review my folder structure or if i don't remember what file i'm looking for, for whatever reason scrolling through the file tree can helps jog my memory even if i don't see what i'm looking for.
@u9vata6 ай бұрын
If your code is well structured, finding in a file tree where to PUT things and how to keep things organized is helpful. So its useful - just not useful to always have it open. I think its even bad if its always open because then it does not scale and structure is either shit or so small I wouldn't care. Also you think you can rely on LSP always. Guess what for game development you might have tons of assets (binary files, like 3d models or textures) and you also want to organize those too. Btw I worked in over 1-2mloc codebase where its tree was so clear, that you found things without fuzzy search just by directory structure pretty much always - and its a good property, because when you add something new you do not add at random places, but where it belongs and things keep being well structured. I also worked in smaller codebases where the only way to know where is what is grepping things around (not even lsp-ing, because it was dynamic language - also using string property names etc. etc.) So I think its useful - but I agree with you it should not be always open - just on-demand open.
@erikslorenz6 ай бұрын
Ever since I added a shortcut in vscode to center the editor I hide the file tree. Between ctrl p and experimental search shortcut I’ve got actually navigating down pretty good. I use basically the same commands as telescope
@orderandchaos_at_work6 ай бұрын
I have no memory of this place
@churraskindequeijo84186 ай бұрын
I like file trees to create, delete and modify files and also to give some context. I keep it close tho (Actually I dont have one because I use Helix)
@ihnatklimchuk10186 ай бұрын
The author has brain damage. People use it because they like it. Meanwhile, I have a question: why do people get mustaches? Is it the same reasoning?
@chaitanyadubakula6 ай бұрын
I just wanna know what fuzzy finder the Primeagen was using to search for files at say 3:08. Because I've seen zoxide do similar things but I don't know if it has search window like that.
@Just_Areki6 ай бұрын
It's a skill issue - I have a bad memory. So opening file tree from time-to-time is necessary to find file I need to work with. Ofc I will use fzf if I remember how it's called or parent folder names
@thedeathstar4206 ай бұрын
I was wondering the same thing. The telescope + grep method is amazing to just jump where you want to go almost instantly
@MrLotrus6 ай бұрын
How prime got this quickfix selection behavior? He changes his file selection in quickfix and his cursor still in buffers with opened files.
@MrLotrus6 ай бұрын
I guess i found. cnext, cprev commands
@isocuda6 ай бұрын
"Files go in Folders" is more syntactically correct than directory and goes back to the 1950s. Distro Divas can stay mad.
@ismbks6 ай бұрын
that's just guessing unless you wrote said codebase
@TheOnlyJura6 ай бұрын
I want to find a file, I know what that file is about, maybe I forgot the name, but I know where it is. That's why I use file tree
@alexeyl17396 ай бұрын
Folder structure is code structure
@spacecowboyofficial6 ай бұрын
Conditioning.
@PikminGuts926 ай бұрын
Bad Prime take
@OffroadTreks6 ай бұрын
Do you not work on big projects and have multiple files open at once? I do a lot of refactors of code bases and I'm always jumping files. It's not a skill issue.
@simonhylander74896 ай бұрын
harpoon :)
@sirhenrystalwart83036 ай бұрын
Wait, you really switch which file you editing by re-opening it in the file tree? Yes, this is a skill issue.
@OffroadTreks6 ай бұрын
@@sirhenrystalwart8303 No I don't nerd. But you apparently don't compare multiple windows side by side. Keep seething with your skill issue cope
@SanbidDev6 ай бұрын
Keybinding please how ?
@atillacodesstuff12236 ай бұрын
yo lsps are magic
@nuttygold59526 ай бұрын
Is this a take that needs to be had?
@brunomello74996 ай бұрын
when I need to create/delete/rename/move files, especially a bunch of them doing this a bunch of times with netrw totally sucks but yeah, having a file tree opened 100% of the time makes no sense
@naranyala_dev6 ай бұрын
try floating file tree, name "carbon" nvim
@scben6 ай бұрын
because they are pretty
@abdussomodadigun17606 ай бұрын
He should make aliases for cd and mkdir to cf and mkfol
@unusualdri6 ай бұрын
He talks like having a file tree is hurting someone. It's just a bit of help.
@nomadshiba6 ай бұрын
while you write code i have no idea what you are doing i mean i understand the code but i have no idea about your code base you always zoomed in (maybe for the stream) and just jumping between parts i cant even follow which files you are editing, it just looks like big blob of random code and you are just throwing random code at random files. i mean you also use tilling wm, and i have a problem with that too, you always show or dont show things, you cant stack, i have no idea what you have running in the background. you also dont use devcontainers or pods. there are probably bunch of random development related packages on your system, and bunch of random (.) files and dirs on your home folder. i cant visualize your codebase, i cant visualize your system. idk how you feel in control. sometimes you have 2 related things at 2 completely different places, keep jumping between them, because its easy with "search", but for someone coming from outside that makes no sense. how do you search for something without knowing what is there? you cant keep the whole code base structure in your mind all the time. without knowing what is there, how do you search for it? how do you know you have things you dont use anymore? how do you know you have a route that shouldnt exists without seeing the routes. tbh i sometimes find you lost while writing the code, like you go like "f it, just gonna throw this here", you jump from file to file try to understand something, but if you had a file tree you would just see it. i think you go blind most of the time while coding, only care about what you are writing at that time.
@slebetman6 ай бұрын
index.js was a mistake that Typescript blindly copied
@vitalyl13276 ай бұрын
Image-based environments are underrated. Smalltalk, to some extend Common Lisp (though it became too file-based recently).
@malcolmkahora53186 ай бұрын
Agreed, using a file tree is a skill issue 99% of the time
@coolguy69verycool6 ай бұрын
The skill issue comment hurt. I just need to learn how to use fizzy search more... :(
@andherium6 ай бұрын
I can imagine that you genuinely don't need a file tree. Ok. But really, is it that hard for you to understand that someone else does? Like you can't even comprehend it? Be reasonable and stop having strong opinions on a weak basis every time.
@natescode6 ай бұрын
You have a strong opinion with a weak basis.
@koijoijoe6 ай бұрын
Do people who don't like to say folder also pretend that they do not have a Desktop and Documents DiRecTOrY, cause its not like its just folders lol every desktop OS has adopted the idea that your FILES are arranged like an office with a desk and filing cabinet in it. Better stop calling files files if you don't say folder cause they're only called that because files are what you store in a FOLDER
@IronJmo6 ай бұрын
I'm going to start calling my hard drive a file cabinet.
@plaintext72886 ай бұрын
Counter question: why prefer folders? Are there any folders in persistent memory? Don't think one can fit in a drive I'm joking ofc, and honestly think that it's partly heritage of the original name, partly elitism😂
@Ivan-Bagrintsev6 ай бұрын
What a BS, man
@sutirk6 ай бұрын
I think it's mostly due to number of syllables. Folders just flow nicer than directories. And ain't no one calling them DIRs
@koijoijoe6 ай бұрын
@@plaintext7288 i think its useful to know the more proper term for them for sure haha but language changes so much it its never going to honor what is the most technical and proper haha. Gif vs jif is actually the greatest language case study ever if you can stop arguing about it for 2 seconds lmao
@kungfucj6 ай бұрын
cuz how the fuck you doin that
@PercyGTM6 ай бұрын
If you still wanna use a file tree, "mini.files" is the best. Better than oil.nvim or nvim tree.
@ketimcodes2 ай бұрын
This guys is always trying to make other feel as if he knows everything. Whatever we do, if he doesn't do it, it's stupid, skill issue, or whatever. Funny thing is that he doesn't work anymore thanks to his skill-issued viewers.