Not actually a doctor.
What? Your colleague sounds like they may be struggling with some serious cognitive issues, they may want to see a doctor about that. As for me, I’ve been living with my brain my entire life, and have kept several different sleep schedules in that time, for one reason or another, including rigid adherence to a schedule you would certainly approve of, and at no time has the basic fact that my brain works better later in the day ever changed. Some people never learn that their own circumstances and experience are not universal. Maybe try not to be one of those people.
Programming is the art of juggling of state and control flow
Sure, stateless functions deal with and impact state in some way. If that’s what you meant by your previous comment, that’s fine, but that’s honestly not what would typically be meant by “juggling” state.
The part about declarative languages has nothing to do with state. Declarative languages do not give the programmer control over flow, the other part of your definition.
Learn Lisp, and you will never again be so certain about the difference between a programming language and a data format.
No, my question does not imply a pure functional language at all. Pure functions exist in languages which are not purely functional. Most of the functions I write are pure functions. I could have a workflow where I work with another programmer who handles the minimal stateful pieces, and I would only write stateless functions - would that make me not a programmer?
(There are also purely functional languages, by the way. I just didn’t remotely imply there were, or make any claims about them, at any point in this thread, prior to this parenthetical.)
The part about declarative languages has nothing to do with state, or functional languages. Declarative languages are a whole different thing. Of course declarative languages handle state. The comment I was replying to said “Programming is the art of juggling of state and control flow”. Declarative languages don’t involve juggling control flow.
You only named one upside, I can’t think of any other, and C-like syntax is pretty common, so it’s not much of an upside. It’s at least debatable whether the JVM is a good thing at all - the majority of languages get along perfectly well without it, and there’s no reason to believe the ones that do target it wouldn’t be doing just fine if it didn’t exist. It’s weird to say Java gave a job to anybody - the demand to have software written resulted in programmers being hired; if Java hadn’t been pushed on the market by Sun, it would have just been another language. Java didn’t establish any fundamentals at all, it just borrowed from other places. While all three of the other languages you mention are interesting, for sure, I’m not sure why somebody who doesn’t like Java should limit themselves to JVM languages.
I get the feeling you feel like I was somehow calling you out. I want to clarify the the intent of my message was more in the spirit of “wow must be nice” than “you’re making that up”. But also I’m just interested in how different your experience is from mine.
Who said anything about only requiring 1 reviewer?
I must have misunderstood. You said “If no one has reviewed your change within 24 hours you are allowed to approve it yourself.” To me, that sounds like, after 24 hours of no review, one self-approval is considered sufficient. That, in turn, seems to imply that before 24 hours, one non-self-approval is probably sufficient, no?
You should try working for a healthy team where everyone takes collective responsibility and where the teams progress is more important than any one person’s progress.
I’ve had team members in the past who are very self-focused, they tend to close a lot of tickets and look good, then get promoted out, leaving an unmaintainable mess behind. Allowing that is generally a failure of leadership. But right now, that’s not our problem, and what you describe is pretty much how we operate.
I’d love to work on a team where everybody took code review a lot more seriously, believe me, it’d be nice, but my team does generally get everything approved, with at least two non-self approvals, in under 24 hours. If something is getting ignored because people are busy and it’s a large change because we aren’t perfect, and there is some reason to get it in soon, it just takes a quick request on Slack to get the needed attention.
What I found surprising about your description was more that the potential of a self-approval coming up would, in itself, get people’s attention, rather than somebody reaching out personally and asking for a review.
Our big weakness is review quality, not quantity. It’s crazy the number of times I look at something and see the two or three approvals already, start going through it, and find issue after issue. I see that on other teams as well, where there’s usually only one or two devs who ever really make any comments on a review, it seems to be very common.
I’m an old emacs warrior, tired of the war. I’m Church of Emacs, but why? I don’t know what I don’t know about the advantages of vi/vim, I only know that when I see other coders use them, they seem to weave the magic about as well as I do.
I know that I have a ton of built-up configuration code that makes emacs the perfect editor for me. I know that I can’t imagine using git much without magit, or how I would organize anything without org-mode, or how I could tolerate the frustration of editing in a container on a remote server without tramp. I know that I have a huge familiarity bias.
I know that whenever I see anybody with with any of these flashy new-fangled editors, they spend most of their time futzing around with dials and buttons and other gadgets, and thinking about how cool it all is, rather than thinking about the code. They start projects really quickly, they handle some refactoring edge cases slightly faster, but they take forever to do any real work, and are completely unprepared to do anything with a new language or text structure at all.
I say: Vim and Emacs against the world.
Even when Emacs had two GUI versions, the default keys were pretty much the same between them, as far as I recall, excepting features missing from one or the other. For a very long time now, it’s all been reconciled as GNU Emacs, anyhow, whether CLI or XWin GUI, or even on a Mac or (shudder) MS Windows. I just use my local running Emacs, with my preferred configuration, to edit files anywhere, such as inside a running container on a remote server in AWS, so it’s pretty consistent for me.
I think I misunderstood you, when you said “manually”, to mean as a human intervention in the process. What you’re showing here is an extra processing step, but I wouldn’t call that manual. Just want to clear that up, but I’m still down to play.
Instead of three greps, you could use one sed or awk. I don’t think there’s anything particularly wizardly about awk, and it would be a lot less cryptic, to me, than this chain of greps.
But a much better idea would be to use sensors -j
to get json output, intended for machine reading, and pass that to jq
. Since I don’t have the same sensors output as you, I’m not sure exactly what that would be, but I am guessing probably something like:
sensors -j | jq '."nvme-pci-0200".Composite.composite_input'
I look forward to seeing how you would do this in PS. As I said previously, I don’t know it at all, so I’m not sure what you’re comparing this to.
first grepping some output to get the line you want and then removing the leading and trailing garbage on that line manually
That’s not what we do, though. Give me a more concrete example, and I’ll let you know how I would expect to do it in a nix environment. I’d be curious to compare. Since I have zero experience with powershell, I am not really sure what to expect. The couple times I’ve glanced at a powershell script it looked awful, but I could be falling into Paul Graham’s blub paradox there. OK, I don’t think so, but maybe.
The only reason you think “master” makes sense is because you’re used to it. It’s actually quite a weird connection to make, if you aren’t used to it. “Main” is much more straight forward. And nobody is really demanding people stop using “master”, so far as I am aware, it’s just that people are making that choice themselves.
A scripting language is certainly a programming language. In fact, it can be hard to even draw a line at all. PHP is just-in-time compiled, and has static analysis tools that can catch errors that are normally considered “compile-time” - scripting language or no? Is Typescript compiled? Are JVM bytecode and WASM just very low level scripting languages? Can you write a powerful web application using BASH? What even is Lisp, in this context? “Scripting language” is a poor abstraction, really.
That’s how you talk?