It’s a typo. The colon should be a semicolon. But since it’s the last declaration, it’s optional.
It’s a typo. The colon should be a semicolon. But since it’s the last declaration, it’s optional.
I never understood this logic
You’re looking for logic in a joke.
Do you question why Donald Trump, the pope and a kid are the only passengers on a plane that’s about to crash?
More like
Problem → new ProblemSolverFactory().createProblemSolver().solveProblem();
What you’re showing here is an extra processing step, but I wouldn’t call that manual.
Yes, it’s not manual by the dictionary definition, but it is an extra step. This is another meaning of manual in my particular bubble [Edit: that I didn’t think to specify].
But a much better idea would be to use
sensors -j
to get json output, intended for machine reading, and pass that tojq
.
This is my initial point, exactly. Dealing with objects is way easier than using the ‘default’ line-wise processing. Only Powershell made that the default, while in Linux you need to hope that utilities have an option to toggle it on – and then also have jq
installed to process the objects.
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.
[Edit, since I forgot to answer your main point:] I don’t program in PS. I don’t like the verbosity. But I do think MS has a point in pushing objects as the prime unit in processing instead of lines.
For instance: Get the temperature of the “Composite” sensor from this output:
$ sensors
k10temp-pci-00c3
Adapter: PCI adapter
Tctl: +37.1°C
BAT1-acpi-0
Adapter: ACPI interface
in0: 16.07 V
curr1: 1.80 A
amdgpu-pci-0500
Adapter: PCI adapter
vddgfx: 1.46 V
vddnb: 918.00 mV
edge: +35.0°C
slowPPT: 1000.00 uW
nvme-pci-0200
Adapter: PCI adapter
Composite: +28.9°C (low = -5.2°C, high = +79.8°C)
(crit = +84.8°C)
acpitz-acpi-0
Adapter: ACPI interface
temp1: +37.0°C (crit = +120.0°C)
Without a cryptic awk incantation that only wizards can understand, that would be:
sensors | grep Composite | grep -Po 'Composite:.*?C' | grep -Eo '[[:digit:]]{1,2}\.[[:digit:]]'
Don’t you think immediately getting the property you’re interested in from an object is easier and more readable than first grepping some output to get the line you want and then removing the leading and trailing garbage on that line manually?
I thing PS scripting would be much more fun if the words weren’t so annoyingly long.
If you edit code with find/replace, you need a better IDE. Just a hint.
That’s where my ecosystem shines, since it’s all open source. If there’s a bug that I can fix, but the maintainer won’t, I’ll just fork the repo.
No clue. My college course wasn’t all that deep, and it’s been quite some time.
Don’t the big internet-y routers also send packets to multiple interfaces if they don’t know how to correctly handle the target IP address?
You forgot to mention that you might get it twice, or thrice, or more, and in different versions.
I’m surprised that after almost 20 years of versioning C code, git still manages to assign the closing brace of a function wrongly.
I’ll take LibreOffice Writer over MS Word anytime. All that ‘I know better than you,’ ‘You wanted to copy the space, too, right? Even though you stopped marking before it,’ can kiss my ass.
no web application build tools track dependencies between source files for incremental compilation
Angular builds are incremental by default.
Web development must be easy
Why should that requirement hold for web development but not for any other kind of development?
it must be possible to iterate very quickly (which requires there to not be a compilation step)
Again, Angular makes an incremental build in about a second, maybe 5 for large applications. Compare this to Java, where even simple backends require 20–30 seconds of build time.
Web application code must be simple and understandable (which requires the application to use a minimum of libraries and frameworks)
This makes no sense. Which is simpler – a function called mergeObjects
from a library or a recursive function of 30–50 lines to do this without the library? Libraries’ whole purpose is making things simpler.
Web applications must be fast and not crash (which requires a compilation step […])
Ever heard of just-in-time compilation?
TypeScript, but they seem to have exhausted the supply of such individuals
TypeScript has minor-point releases about every 3–4 months. What makes you think it’s dying?
To conclude, because this post is long enough: Your comment is full of opinions, but little else.
Are web servers that serve real HTML responses still a thing? Honest question. I thought JSON+client side rendering were the default by now.
Piped link: https://piped.video/watch?v=TIZKKmh6YM8
Who sends API requests if not frontend developers?
If your bandwidth can afford more than 3bps:
Source: https://twitter.com/nixcraft/status/1422824132249473025/photo/1
Yep, and
align
isn’t a real property, either.