RANT – DRAFT
*I always add the verbose flag (-v) to a lot of my CLI commands. I just like having the comfort of being able to see results printed to the CLI so I can verify that what ever command I issued, had the result of what I intended to do. It’s better than simply no feedback at all, which is the default when most commands executed without error…syntax error that is. What if you missed typed the permission settings but the command it self still happened to be valid. You wouldn’t get an error, and a slight mistake like that is very easy to miss.
By getting in the habit of using the –verbose flag when ever its available as an option is a quick way to just double check the results of your command. I know in my case on more than one occation where I noticed the permissions weren’t set how I wanted them to be set by glancing at results.
Then it plays out like this:
Hmm… Hit up arrow on keyboard, oh yeah…forgot to include the group when updating permissions. Let me just fix that really quick…[clickity clack][ENTER]…a second later I glance at results…yup… looks good… glad I spotted that…that could of caused some issues for the devteam down the road…
Alternate non-verbose universe plays out like this:
Son of a bitch, I got the devteam going ape shit because they don’t have access to some folder…let me drop whatever I’m working on to see what the problem is. (Open File Browser or CLI, navigate to the culprit folder)…shit…yup, I definitely left out the group option when updating the permission settings with chmod yesterday…I’ll fix that right quick…[clickity][clack][clack][clickity][click][thump][clack][clack][ENTER]…(more keystrokes because I had to type out the whole command)…all fixed…devteam thinks I’m a hero because I fixed the issue in 3 minutes.
What they don’t know is it cost you 15minutes out of your day because you didn’t take .5seconds to type the –v flag to double check the commands you were executing we’re in fact producing the results that you had intended.
See the problem here?
Now this trend of typing as few keystrokes as possible is mostly related to source code I’ve seen over the past year. I though a hypothetical example of a command that gets executed on the CLI, that just has a simple issue of just mis-typed command that doesn’t return any error would paint a better picture & is actually probably a more common situation than we’d like to admit.
I just find it ridiculous to pretend that typing a few extra keys here & there amounts to hard labor. Sure, may be a couple strokes here & there will maybe add up to hundreds of extra key strokes by the end of a work week. Are younger developers really that lazy. I’m suck it up.
Do these hipsters not consider the actual cost? It’s all a short term mind set of “Hey I can save a couple seconds now, but I’m screwing myself tomorrow when I can’t figure out this crypitic function that’s not working as expected.”
What they’re essentially doing is trading a couple seconds now and gabling hours of there lives in the future trying to read source code that’s got a function crammed into 1 line of code or trouble shoot why there is access restrictions on a project folder. My hypothetical situation, which I feel is very plausible, shows that having a short sighted mind set & not thinking about the bigger picture, only thinking about the here & now will more often than not, bite you in the ass.
Time is our most presious commodity & gamling with it by only thinking about seconds saved now & not realizing hours lost in the future when things go wrong.
I’ve said in the past that you can always make more money tomorrow, but you can never make back the time lost today.
I’ve seen it in Youtube turorials, online articles, written tutorials and basically see hints of this mis-guided attempt at being efficient written all over everything related to computer science.
I’ll end with this actual real world example of what I’m talking about. On Youtube, on a Code School Channel of sorts (at least that’s what they claim), the instructor…let me reiterate…THE INSTRUCTOR! Actually showed an example of taking 11 characters out of a line of code only to end up typing out a whole function right after.
Now some may say, well it’s good to clean up code and maintain Separation of Concerns (https://en.wikipedia.org/wiki/Separation_of_concerns ) . To this I respond: I agree. My problem is, is that this dude actually stated his reason for the change was: “incase you didn’t feel like typing out the whole method.”
You could then type out a whole class method using a PHP magic method that is far from best practice to make the line of code work!?!
What!?!
Here is the link to the video: https://www.youtube.com/watch?v=_Yh7b8UJUCk
I actually left another rant in the comments a couple week ago because it just blew my mind.
Yes, I realize I’m being overly dramatic and this has turned into a rant that started by a recommendation to use the verbose flag, to: if you don’t you will lose hours in your life that you will never get back…
But I just wanted express one of my frustrations (of countless many) with a trend I’ve noticed over the past year that I’ve returned to the IT sector.
I’ll leave you with this:
Don’t try to save seconds today at a cost of minutes tomorrow.
Good luck out there, Brandon