|
Kebab-Case-For-Life
|
# ? Dec 29, 2017 23:20 |
|
|
# ? May 12, 2024 19:06 |
|
Aaronicon posted:Kebab-Case-For-Life This is filthy and I love it
|
# ? Dec 30, 2017 01:54 |
|
Taffer posted:If you're going to alter naming for local vars why not use hungarian notation instead, seeing as it's something of a real convention already? But the real answer is that you should do neither because a good IDE can make it immediately obvious which variables are local or not, and well designed functions (i.e. small ones) will be easy enough to read that it's obvious without any help like that. I see this argument a lot for certain style guidelines; but it assumes that code will always be read in an IDE that is properly configured to do so. Maybe a valid assumption in some development environments, but it has never been valid in any I've ever worked in.
|
# ? Dec 30, 2017 06:33 |
|
Aaronicon posted:Kebab-Case-For-Life I guess my stomach bug is done because I'm legit hungry now.
|
# ? Dec 30, 2017 08:48 |
|
I saw a style guide recently (maybe for Angular?) that said to just use normal variable casing for constants, because all uppercase is hard to read and your IDE will identify constants anyway.
|
# ? Dec 30, 2017 15:26 |
|
Glad this isn’t the coding horror thread because I’m likely the horror, but I hate all of these “Your IDE will do it for you” ideas. Yes, my main IDE will do it for me, but I wonder: 1) How many people have full context highlighting diff tool attached to their git diff? 2) Have github’s browser showing full local vs constant? 3) Ever hop in a different IDE based on need? Jetbrains vs Sublime text for instance? 4) Ever drop to the command line with a vim invocation that may not have the whole project set up? 5) Have an online code review system that you read code in like FishEye or Code Collaborator? 6) Ever send or receive a snippet of code in HipChat or Slack that lacks the full context to highlight anything beyond what the language does? Etc... 95% of the time the IDE is there, but *I* at least run into 5% where it’s not in one of those above. And most of those times in that 5% it’s pretty drat critical to know the difference because you’re doing it for an outliner of an issue anyway.
|
# ? Dec 30, 2017 15:54 |
|
I don't typically use IDEs so
|
# ? Dec 30, 2017 17:32 |
|
Pollyanna posted:I don't typically use IDEs so Imagine you were a contruction worker and you just told me that you dig sewer lines by hand.
|
# ? Dec 30, 2017 18:01 |
|
I will grant that you could have created some custom thing using tmux or whatever, but I will never understand the pride of a tool maker about not using tools.
|
# ? Dec 30, 2017 18:03 |
|
Genuine question. Without looking, what would you guess I work on?
|
# ? Dec 30, 2017 18:04 |
|
Pollyanna posted:Genuine question. Without looking, what would you guess I work on? very high level scripting where the scripts are at most 100 lines long. For that, an IDE is definitely not needed, nano does the job quite well. For anything more, one needs to be a special kind of masochist to enjoy it and keep at it.
|
# ? Dec 30, 2017 18:11 |
|
Pollyanna posted:Genuine question. Without looking, what would you guess I work on? I might have looked but I would guess JavaScript or another sufficiently-dynamic language. I have been pretty much all-in for IDEs since Turbo C++, but they had far less value when I could not navigate well with them. A particular event with Python happened some years ago with IDEs. We had previously been doing C# and had ReSharper licenses, so I eventually learned about PyCharm. I remember telling my boss PyCharm was "apparently God's gift to Python" and I would assess it. I came back a day later with my hair turned completely white to confirm that yes--YES--it was that much better. Eventually I was doing Django stuff and Angular and decided I might need the commercial features. Suddenly it started to call out most of my bullshit in the JavaScript files too.
|
# ? Dec 30, 2017 18:26 |
|
Pollyanna posted:Genuine question. Without looking, what would you guess I work on? IIRC you did some Ruby and webshit, so I am gonna guess JS and webshit now?
|
# ? Dec 30, 2017 18:34 |
|
Pollyanna posted:Genuine question. Without looking, what would you guess I work on? Cocaine and Pity
|
# ? Dec 30, 2017 19:23 |
|
geeves posted:Cocaine and Pity I was just going to say Pity, but yeah, Cocaine as well.
|
# ? Dec 30, 2017 19:26 |
|
Pollyanna posted:I don't typically use IDEs so We know that’s why you were so confused by the greatness that is JetBrains products *ducks*
|
# ? Dec 30, 2017 19:34 |
|
Does SublimeText count as an IDE? I've been annoyed with devs before who couldn't read a diff on GitHub or a code snippet because they didn't have their precious IDE handy...I guess I'm a carpenter who refuses to use power tools...
|
# ? Dec 30, 2017 20:41 |
|
You shouldn't underestimate the amount of discipline that following variable conventions instills. Your editor might be 100% perfect at picking up local vs global, private vs public, etc. But if you have a convention readily available reading the code becomes easier. You don't have to remember (say) that a particular variable is a public int value; you just have to remember the naming convention. And code is read more often than it's written. Not saying everyone should use Hungarian notation, or even extremely rigid conventions (I don't), but keeping in mind consistency is important because you're not having to juggle tons of extra stuff in your head, even when you have an IDE with tons of extra tools at your disposal.
|
# ? Dec 30, 2017 20:47 |
|
vonnegutt posted:Does SublimeText count as an IDE? With thirty or so plugins it sure can. Some people at work do all their development in SublimeText. I use it when I need to quickly find some random script in a git repo of 1000+ random scripts. (Don’t ask, please, please Don’t ask.)
|
# ? Dec 30, 2017 20:59 |
|
Ghost of Reagan Past posted:You shouldn't underestimate the amount of discipline that following variable conventions instills. Your editor might be 100% perfect at picking up local vs global, private vs public, etc. But if you have a convention readily available reading the code becomes easier. You don't have to remember (say) that a particular variable is a public int value; you just have to remember the naming convention. And code is read more often than it's written. Exactly. A convention should be followed, consistent within at least the individual project (though I personally don't care if there is a different style between projects). The IDE is there to make following it easy and automatic - little squiggly lines when things don't fit the convention and full refactoring in a single click is the best.
|
# ? Dec 30, 2017 21:20 |
|
vonnegutt posted:Does SublimeText count as an IDE? SublimeText counts as nano not an IDE. A tad better than writing code using butterflies. As for developer's ability to read a git diff without a git UI ... that's a different issue altogether. One should be able to write C code with nano, but one cannot argue that it is more efficient than a full featured IDE (well, they can argue of course, but they'd be obviously wrong).
|
# ? Dec 30, 2017 21:54 |
|
Hughlander posted:With thirty or so plugins it sure can. Some people at work do all their development in SublimeText. I use it when I need to quickly find some random script in a git repo of 1000+ random scripts. (Don’t ask, please, please Don’t ask.) Yes this. Vim with appropriate plugins can work similarly. IIRC there's that YouCompleteMe plugin for vim that makes it a very good C++ editor. I was actually starting to get into vim so that I could work on that, but both my personal and professional hobbies have taken me away from C++ lately. Then JetBrains pooped out CLion. However, I remember having this IDE chat with a coworker ~6 years ago when they were working on tens of thousands of lines of C# and says, "Vi's all the IDE I ever need" and wheels around to show a virgin vi terminal. IIRC he had contributed something like double-digits of code to that project. Either that's all he needed personally because that's all he had to do, or that's all he was capable of doing. A few years back I finally understood the scope of the elitist macho that pervades a certain amount of software development. I am sure people can trace this to other cultures of engineering. I had the disease too because I had learned C++ so young and had my head up my rear end over it. I finally did some Perl scripting when I was 20 for my first internship and realized that when your tools make things simpler, you compensate by tackling harder problems. And furthermore, when you employ good software development conventions, they make certain things simpler so you can tackle harder problems. So I can sit smug about hand-optimizing a loop in C++ or pick the right rough algorithm from a library, move on, and probably have a faster solution at the end. Oddly enough, working in a performance analysis job taught me this when I would have figured it would have reinforced it instead, but I was also doing this for the sake of improving compilers, so I guess it did a lot to show me how good compilers can be. Uhhh disclaimer here: I'm not making GBS threads on C++ developers in general, by the way, and I am sure the seasoned C++ developers know people I am talking about and want to lobotomize them with rusty screwdrivers.
|
# ? Dec 30, 2017 21:58 |
|
Volguus posted:SublimeText counts as nano not an IDE. A tad better than writing code using butterflies. As for developer's ability to read a git diff without a git UI ... that's a different issue altogether. One should be able to write C code with nano, but one cannot argue that it is more efficient than a full featured IDE (well, they can argue of course, but they'd be obviously wrong). Use the best tools for the job; that can be an IDE, or it might be a fully-featured text editor. People shouldn't worry about tools too much, especially the tools other people use. If you are good at what you do and use good tools, you'll get good results. Nobody's hamstringing themselves because they use SublimeText instead of a Jetbrains product or Visual Studio--even if they'd be perfectly fine with those (and I do love Visual Studio)!
|
# ? Dec 30, 2017 22:40 |
|
Ghost of Reagan Past posted:Nobody's hamstringing themselves because they use SublimeText instead of a Jetbrains product or Visual Studio--even if they'd be perfectly fine with those (and I do love Visual Studio)! Rocko Bonaparte would have to disagree: Rocko Bonaparte posted:However, I remember having this IDE chat with a coworker ~6 years ago when they were working on tens of thousands of lines of C# and says, "Vi's all the IDE I ever need" and wheels around to show a virgin vi terminal. IIRC he had contributed something like double-digits of code to that project. Either that's all he needed personally because that's all he had to do, or that's all he was capable of doing. The point is: use the tools that actually help you do the job, not the tools that make you look cool in the eyes of the co-workers. I used Borland C++ 3.0 back in the day. No, I do not want to use Borland C++ 3.0 ever again if I can help it.
|
# ? Dec 31, 2017 03:40 |
|
Rocko Bonaparte posted:Yes this. Vim with appropriate plugins can work similarly. IIRC there's that YouCompleteMe plugin for vim that makes it a very good C++ editor. I was actually starting to get into vim so that I could work on that, but both my personal and professional hobbies have taken me away from C++ lately. Then JetBrains pooped out CLion. As someone who uses vim for C# development, I would be completely useless without omnisharp-vim. And by completely useless, I mean I would use VS because I’m not dain bramaged. I also try not to recommend vim to people, because I run into too many people that are all “I love vim, I use it for everything ” that barely know how to switch modes and have no configs. But they read a blog post from someone once and now they refuse to use functional tools or put in the [excessive, poor use of] time to make vim useful and understood.
|
# ? Jan 2, 2018 03:47 |
|
The educated vim user understands they persevered long enough to do permanent damage to their psyche such that they can no longer use other editors, and therefore understands to not recommend that sunk cost to any more people so long as they live. (Uhh, I’m a vim user, very tricked out config though)
|
# ? Jan 2, 2018 12:22 |
|
Maluco Marinero posted:The educated vim user understands they persevered long enough to do permanent damage to their psyche such that they can no longer use other editors, and therefore understands to not recommend that sunk cost to any more people so long as they live. (Uhh, I’m a vim user, very tricked out config though)
|
# ? Jan 2, 2018 14:17 |
|
I'm thankful that there are enough broken people out there that vim bindings exist for nearly everywhere I might want to edit text, but it sure would be nice to not have to flail around helplessly when faced with a normal text box.
|
# ? Jan 2, 2018 20:39 |
|
We had to do a hotfix on the 26th that involved a cronjob. Crontab -e opens a vi editor and I had a giggle has my cto stumbled around going wtf is this how to i add a new line. I didn't know either. I use nano when I'm ssh'd.
|
# ? Jan 2, 2018 20:43 |
|
Plorkyeran posted:I'm thankful that there are enough broken people out there that vim bindings exist for nearly everywhere I might want to edit text, but it sure would be nice to not have to flail around helplessly when faced with a normal text box. You have this plugin, don't you? http://www.viemu.com/viemu-vi-vim-word-outlook.html
|
# ? Jan 2, 2018 20:47 |
|
Can anyone explain to me why anyone uses vim for any reason? If you're doing normal coding why would you not use an IDE or at least a good editor like sublime? Even when I'm in CLI I use nano, because gently caress vim and all its byzantine nonsense.
|
# ? Jan 2, 2018 21:03 |
|
Taffer posted:Can anyone explain to me why anyone uses vim for any reason? If you're doing normal coding why would you not use an IDE or at least a good editor like sublime? Even when I'm in CLI I use nano, because gently caress vim and all its byzantine nonsense. played a lot of nethack
|
# ? Jan 2, 2018 21:08 |
|
Taffer posted:Can anyone explain to me why anyone uses vim for any reason? If you're doing normal coding why would you not use an IDE or at least a good editor like sublime? Even when I'm in CLI I use nano, because gently caress vim and all its byzantine nonsense. I do not use an IDEA if I have to open a large text file for any reason. IntelliJ and others may just slow to a crawl if not shut down entirely, even on files as small as 1mb. If I have a file over that size (even smaller) using a lighter weight program is preferable because usually at that point I'm looking for errors or looking to do large scale search and replace testing and using Text Wrangler or vim through Terminal is the better way to go.
|
# ? Jan 2, 2018 21:09 |
|
Can any of the vim brokebrains explain their general text editing thought process? It's a serious question. The impression I got from vim was to think of the individual characters positionally in space and exploit vim's character navigation to get exactly where you want to go from where you started in as few keystrokes as possible.
|
# ? Jan 2, 2018 21:12 |
|
Learned it and emacs writing C on Solaris machines fifteen years ago. Ended up settling on vim over emacs as a matter of happenstance. If you need an IDE, use an IDE of course. But if you need a text editor, there’s not a compelling reason to prefer Sublime or Emacs Or Vim over the others, really - just use the one that feels good. I used Sublime for about a year ‘cause that’s what everybody else on my team used and I didn’t want to be the odd man out for pair programming and stuff, but ended up back on vim.
|
# ? Jan 2, 2018 21:16 |
|
VIM is nice when you want to just see the code and nothing else, IDEs tend to be visibly slow and showing a lot of unnecessary detail. It's a bit difficult to beat the performance when remotely editing files. I only modify VIM to save per-file edit position, I cannot remember pretty much anything more than the simple editing functions. Copy & paste is utterly awful and I usually hop into Sublime to do that I work in a domain that the debugging features are usually of no assistance though, that's my excuse. Plus project management is usually totally retarded in MSVC. MrMoo fucked around with this message at 21:19 on Jan 2, 2018 |
# ? Jan 2, 2018 21:17 |
|
I learned Unix sysadmin back in the early 90s far before I was even semi-competent at coding and on those old RS-6000 boxes running AIX vi was the best I’d get. Not even vim proper was possible on those machines with the way they were locked down. I was earning my graybeard before I even had facial hair
|
# ? Jan 2, 2018 21:27 |
|
Taffer posted:Can anyone explain to me why anyone uses vim for any reason? If you're doing normal coding why would you not use an IDE or at least a good editor like sublime? Even when I'm in CLI I use nano, because gently caress vim and all its byzantine nonsense. You have to use vi when working on a freshly installed *NIX os as most do not install nano by default, even if the extent is to change the config files just enough so that you can install packages. Nowadays is no longer that much of a problem as it has sane defaults and one can kinda do without vi, but 20 years ago it was mandatory. Plus EDITOR is set by default to vi so even a simple crontab -e gives you vi. But that's all. Learn to edit & save & exit and you're golden.
|
# ? Jan 2, 2018 21:40 |
|
I work at a small company with a few other devs, the CEO just informed us that the CTO (my direct manager) will be devoting all his time on completely rewriting our core product completely on his own, and no longer manage the dev team. I should start sending out resumes, right? Votlook fucked around with this message at 21:45 on Jan 2, 2018 |
# ? Jan 2, 2018 21:41 |
|
|
# ? May 12, 2024 19:06 |
|
Rocko Bonaparte posted:Can any of the vim brokebrains explain their general text editing thought process? It's a serious question. The impression I got from vim was to think of the individual characters positionally in space and exploit vim's character navigation to get exactly where you want to go from where you started in as few keystrokes as possible. Honestly if you just learn like 5 commands and VsVim instead of actual vim it's not that bad. I really only know the basic navigation and copy/paste/delete/find/replace/quit and it's pretty nice. Though I find it usually takes me longer to make a macro or find/replace regex that works than it would be to make all the changes manually. BUT I DID IT WITHOUT A MOUSE SO ITS AWESOME
|
# ? Jan 2, 2018 21:49 |