6 ms·
For anyone wondering whether or not you really need to know bash: Yes. Yes, you do. Somewhere in the middle of every stack is a bunch of bash and makefiles. Do
by jofer 2y ago
For anyone wondering whether or not you really need to know bash: Yes. Yes, you do.
Somewhere in the middle of every stack is a bunch of bash and makefiles. Don't replace that or avoid it. Embrace it. It's not perfect, but it's important to know.
- almostgotcaught 2y agoI love when people proclaim this as if it's some kind of sage wisdom when it's actually just hypermyopia. For anyone wondering whether this is true: of course it's not since there are plenty of stacks that don't run in environments that are anywhere near a shell.
- jofer 2y agoCan you seriously name something other than very low level embedded software that doesn't involve shell at some level? I certainly can't...
- almostgotcaught 2y agoDo you think your phone runs a shell for IPC? Like passes strings to and fro? How about the runtimes/hypervisors/etc that manage vcpus on AWS? And about that embedded dev - do you think that that's a small niche industry?
- yjftsjthsd-h 2y agoI'm pretty sure Android has a bunch of shell under the hood, and I don't have a jailbroken iOS device to check but I'd be a little surprised if it was different. AWS may or may not, I don't know enough to comment. And yes, about embedded dev - there's the very very low level stuff of course, but the moment you get above tiny microcontrollers it's all Linux again and there's shell everywhere. Actually, even for the really tiny embedded stuff I'd still expect to find a mess of shell scripts, just in the build environment rather than on-device.
- almostgotcaught 2y ago> I'm pretty sure Android has a bunch of shell under the hood I didn't claim there was no shell - I claimed that IPC isn't performed with pipes.
- yjftsjthsd-h 2y agoAnd the kernel also doesn't run shell, but the claim was that you would struggle to find > software that doesn't involve shell at some level which would seem to me to encompass more of the stack. Like... okay, Android IPC isn't pipe-based. Does that release anyone from touching shell? Anyone working on a ROM is going to get their hands dirty with the rest of the OS. And I struggle to believe that any app developer is avoiding it (it's always the build step that does you in). Approximately nobody is working on just IPC in isolation.
- almostgotcaught 2y ago> it's always the build step that does you in Just curious: where exactly is the shell in `cmake -GNinja`? Or is CMake not a build system hmmm? Nevermind that some people use bazel or meson or something ... other than shell... Shell scripts in your build system are a code smell. In cpp projects it's covering up for people that don't how to use the actually correct tool for the job: the CMake scripting language.
- yjftsjthsd-h 2y ago> Just curious: where exactly is the shell in `cmake -GNinja`? Or is CMake not a build system hmmm? Nevermind that some people use bazel or meson or something ... other than shell... Right above it; cmake replaces make, but something still runs it. And IME that something is usually either a developer running it from a shell (ideally eventually with another shell command wrapping it to automatically build on file changes) or a CI system running it which is always a massive pile of shell scripts. To be fair, I don't doubt that if you really tried you could build a dev environment that used zero shell. But you would have to really try, and half of the things you had to build to make it work would inevitably converge to an informally-specified, bug-ridden, slow implementation of half of Common Lisp^w^wBASH.
- jofer 2y agoShell pops up in a ton of places even where it's not used directly. Build systems are a good example. I have yet to come across something that doesn't touch shell at some level unless it also doesn't touch an OS. But maybe that's just me. Phones aren't an exception to that, though.
- wiseowise 2y agoThose things might not run bash/sh, but I’m willing to bet a hundred quid that nearly all of their development environments had at least one tiny shell script that did some transformation of data.
- wpm 2y agoWhether they run in environments where a shell is nearby has no bearing on whether they are built or tested in environments where a shell is near and sufficient for the task.
- almostgotcaught 2y agoPasting what I responded to the other person talking about build systems: Just curious: where exactly is the shell in `cmake -GNinja`? Or is CMake not a build system hmmm? Nevermind that some people use bazel or meson or something ... other than shell... Shell scripts in your build system are a code smell. In cpp projects it's covering up for people that don't how to use the actually correct tool for the job: the CMake scripting language.
- benreesman 2y agoSome things change: you once needed Perl where you now need Python. Other things don’t: you need non-trivial bash. I don’t mind if people do their heavy lifting in VSCode, I like the tool myself. But if you can’t unfuck the little daemon that VSCode talks to? You’re out of commission. You’re at the mercy of people who can.
- deleted 2y ago[deleted]