1. 14

    Isn’t the problem that Babel is somewhat unsexy project being at a dead end?

    A few years ago, if you wanted to write “plain” Javascript and get somewhat ergonomic features (ES6, async/await etc), you had to transpile for backwards compat in the browsers. However browser have caught up. If you are that way inclined, it’s today possible to hand code plain javascript and both get somewhat ergonomic features and run in most browsers.

    But then, does anyone hand code javascript anymore? The sane choice is Typescript (or Rust! or some other typed language), and why would I not use Typescript directly instead of Babel? Ok, granted, Babel has a gazillion plugins and allow for building all sort of things, but it goes into the realms of “bundling”.

    Bundling used to be synonymous with webpack, not sure it is anymore. We use esbuild because it’s blazingly fast https://github.com/evanw/esbuild - and we managed to cram all bundling needs into it (CSS, Typescript, SVG etc).

    Babel is a beast of a project, with an enormous dependency tree. It might just be me, but I actively try to make sure none of our tools (testing, building, bundling) pull in Babel.

    If I were to donate to an open source project in this area. I’d try to find something that takes us out of this transpiling madness, or at least does it extremely fast (like esbuild).

    1. 6

      Despite the hype, I don’t think TypeScript has overtaken JavaScript usage (or is even probably that close, to be honest). I prefer vanilla JS to TS or babelized JS. None of the projects I work on require supporting ancient browsers, so modern browsers do fine with features.

      Babel is a beast of a project, with an enormous dependency tree. It might just be me, but I actively try to make sure none of our tools (testing, building, bundling) pull in Babel.

      I’m not sure why this matters if you’re using babel as a dev-dependency. It’s not like it’s shipped to browsers with your production code.

      1. 5

        I’m not sure why this matters if you’re using babel as a dev-dependency. It’s not like it’s shipped to browsers with your production code.

        Oh, wow. Trust me, even dev-dependencies can cause unwanted hair loss. The fewer things there are, the fewer things there are to break. Not to say it makes sense to get rid of all the things, necessarily… but I sympathize with the desire.

        1. 2

          The concern feels kinda vague to me. I agree it can “feel” weird to pull in large dependencies via npm, but Babel is a compiler. You could say similar things about typescript. I have used both in production and never been aware of shipping a bug that was the result of either tool. If you’re going to use a compiler then you’re trusting and hoping it works, and I feel like the largeness of that tool’s codebase should mostly be a black box to the developer who wields it. Otherwise we could really just say the same thing about any compiler, like ever.

        2. 5

          I prefer vanilla JS to TS

          What’s your reason for this? Whenever I have to switch over to vanilla JS from TS I can feel my productivity slow down by about 10x, and I’m about 10x less confident that the code will behave as intended especially after a refactor or when I have to deal with the this funny-business that vanilla JS developers like to use.

          The intellisense alone is worth the switch, not to mention the number of bugs caught by the type system that would otherwise cause mysterious runtime errors. Personally I would love to take a TypeScript job but for my own sanity would never in a million years accept a job writing vanilla JS.

          1. 1

            My reason for wanting less boilerplate and another layer between what I’m writing and what is actually deployed? :P

            I’m not sure what you even mean with the this funny-business that vanilla JS developers like to use - I don’t use this really ever, but I write functional JS. If I’m writing classes for a project (i.e. if a project uses classes and I want my code to look the same), I use fat arrows to encapsulate this just like you would in TS. TS to me is a way for people who came from things like Java to feel “safe” in a language they don’t quite understand. TS to me is the Java-ization of JavaScript and in my experience at 4 different companies, the people who love TS largely come from that background.

            I’ve been writing JS (vanilla) since the late 90s. It’s a language I know and understand very well. TS introduces complexity (both dependencies and its own type quirks) with little to no benefit for me. I’ve never had issues with types in any of the apps I’ve developed.

            1. 2

              You should be an assembly programmer then! :)

              I’ve witnessed a number of people use this as a “magic” rebindable-at-will state variable to enable/disable certain features of a callback function depending on the context. It might be momentarily convenient for the author, but it’s a huge pain for others to read / maintain.

              The big advantage to TS is the type inference and intellisense, which are forms of baked-in, on-demand, automatically-in-sync documentation. It’s also not just Java programmers who like TS – Haskell programmers feel much more comfortable writing TS rather than JS. I’m sure you’ve heard of fp-ts!

        3. 5

          Isn’t the problem that Babel is somewhat unsexy project being at a dead end?

          All the more reason to pay people to care about the project: if your project uses it, that’s cheap compared to paying developers for keeping up with the JavaScript build system hype train and integrate all the things you need to be sexy and modern.

          1. 7

            “Unsexy” is a very good reason to pay people to work on it.

            “At a dead end” is a very good reason to stop spending money on it. I don’t use Babel at work, even though I write JavaScript, because all of our supported browsers have async/await, and the rest of the ES proposals are nice but not that nice.

            1. 1

              “Unsexy” is a very good reason to pay people to work on it.

              “At a dead end” is a very good reason to stop spending money on it.

              You encapsulated that much better then I could have. Allowing “Unsexiness” to control tech is one of my pet peeves.

          2. 2

            But then, does anyone hand code javascript anymore?

            That’s how Javascript is taught in schools.

            1. 2

              But then, does anyone hand code javascript anymore?

              Sure thing. And you’re exactly right: writing for reasonably modern browsers is reasonably easy. For projects I’ve worked on lately (where the JS component hasn’t been the bulk of the code) it seems to have been a good tradeoff against fussing with a deep development stack.

              1. 2

                There’s a big reason why even in TS projects a lot of people still use Babel: Babel is compatible with TS nowadays, and for development setups it’s much faster than even webpack + TS with the threaded approach.

                I’ve worked on more than one project where for development we had a Babel doing TS (where not all aspects of type checking are as strict on every rebuild) and for production we go with the actual Typescript compiler and do stricter type checking in case the Babel TS checker missed something.

                I believe even the out of the box setups of popular projects starters like Create React App and Next.js do exactly that.

              1. 3

                cc @antifuchs, who wrote the Gmail-britta the author mentions!

                1. 2

                  Nice! Glad to see more people exploring email filter generation!

                1. 1

                  Interesting that this claims a maximum number of 8 digits. I have a yubikey 4c nano holding a gpg-agent based key with a 30-digit PIN. (I hope!)

                  1. 4

                    What happens if you try to activate the key using only the first 8 digits?

                    1. 1

                      Interesting – I didn’t realise the gpg-agent-based solution had better PIN support in that regard! Personally, my PIN is rather short; given that it’s not directly encrypting anything (and the hardware enforces a lockout after 3 failed tries), I don’t think this is the end of the world :)

                    1. 10

                      Neat! I’m unable to read this name without seeing the “please” in there, much like the “meow” in “homeowner”.

                      1. 8

                        I’ve never seen that re: homeowner before. Thanks, I hate it. :|

                      1. 3

                        I’ve been using this trick with my personal dockerfile builds in order to make apt-get installs less of a hassle: mount /var/lib/apt and the other cache dirs as caches, and not only do you save yourself that annoying rm incantation, it even caches package downloads across builds. A huge time saver, and it makes docker files much more readable.

                        1. 2

                          Turns out that offical Debian/Ubuntu base image does cache cleanup automatically after installs, so you actually need to disable that to get the benefit of faster builds.

                          RUN rm /etc/apt/apt.conf.d/docker-clean
                          RUN --mount=type=cache,target=/var/cache/apt,id=apt \
                            apt-get update && apt-get -y upgrade
                          
                          1. 1

                            Oh yeah, I should document that too.

                          1. 1

                            New to tailscale, so I’m probably asking something too obvious, but: What’s the purpose of that setup oneshot service? From what I saw in the docs, you only need the one-off key once, so could you “just” run that tailscale up command on the cli as a regular user (with or without the pre-generated key)?

                            Do you have to re-run it every time the machine boots?

                            1. 4

                              This is a list of various Rust applications that I either use or keep close watch on.

                              I’ve used most, if not all, programs in the list.

                              Can anyone think of anything to be added that I may have missed?

                              1. 9

                                I’m partial to https://github.com/antifuchs/chars (being the author) - I use it every few weeks.

                                1. 2

                                  Very nice, I can see myself using this as well. I’ll add it right now along with spieglt’s software that was shared above.

                                2. 8

                                  https://meli.delivery/ terminal email client

                                  1. 2

                                    Jeez, I actually know of that and follow it’s development. How could I forget to put this on the list!?

                                    Thanks for reminding me, adding it now.

                                  2. 4

                                    I saw you had a Gameboy emulator on there, I wrote an NES one if you’re curious: https://github.com/spieglt/nestur. And a password-based file encryption utility: https://github.com/spieglt/cloaker.

                                    1. 3

                                      That NES emulator looks great, I’ll be sure to add that! As for cloaker; I’ll still add it, but I’m going to add a disclaimer about it using Qt.

                                      This is nothing against you, I just personally have an irrational hatred for Qt.

                                      1. 2

                                        Thanks! And totally get it re: Qt. I hate that wrapping Rust as a static lib in a C++ program was the easiest way I found to have a cross-platform, lightweight, standalone binary.

                                      1. 1

                                        Sorry for the late reply, I was working. Added them!

                                        Though I did add a warning about topgrade, as it runs specific system commands that may or may not be installed on your system. I don’t use it, so I’m not sure if they added error handling for that. But I felt the need to put the warning in regardless.

                                      2. 3

                                        I think people could use this in different ways, but I didn’t see a list of Rust users on the Rust website after a very quick inspection. Your list might be a helpful contribution to the website as some people like to learn by digging into a real project.

                                        1. 2

                                          There’s a very hidden one that was moved over from the last website, but such lists were removed from the current rendition of the page. The reason here is simply: such lists need to up-to-date and maintained (including going through and removing items). The old website had this a ton (such as the famous FAQ and the meetup list). This is a surprisingly high drag on maintainers.

                                          People liked it on an emotional level, but for new users, it was very bad, as meetups went in and out of existence and the FAQ famously stated that Rust is not yet adopted in Firefox when we moved over to the next one. Those are just 2 examples. Our strategy now is that if you feel the urge to add an FAQ, it should probably land in one of the books or some actually maintained documentation.

                                      1. 3

                                        This is a fascinating topic, and my mind can’t get past the illustration you made at the top. It’s really poignant: Is userspace a complex arrangement of creditors, with the kernel sometimes so deep in debt that it has to default (aka, invoke the OOMkiller)? Is swap space the equivalent of an actual credit default swap?

                                        1. 3

                                          Thanks for noticing the picture! :D No one has commented on it much.

                                          Yes, I think there are so many fascinating parallels from this to finance.

                                        1. 1

                                          I really like this way of providing an evaluation license:

                                          Freely downloadable evaluation version of Klennet ZFS Recovery provides all capabilities required to try and test it, including tests on the actual data you need to recover. Thanks to checksumming built into ZFS, evaluation version can determine which files can be recovered intact and which files are damaged.

                                          Seems quite honest, and provides a positive motivation for people to pay.

                                          1. 3

                                            Every time I see this headline, I keep thinking this is about pre-exposure prophylaxis and I get really really confused about the link between HIV and Windows NT. Turns out the acronyms’ capitalizations are different.

                                            1. 4

                                              Meanwhile I remember buying into those heady “PReP is going to take over the world” ideas, so every time I see something about pre-exposure prophylaxis I think it’s about that. Thanks for pointing out the different capitalization!

                                            1. 2

                                              A question borne out of curiosity: What does Ansible and Kubes get you for a small homelab setup over well-managed and behaved systemd units run on one Linux install deployed with something like nixops?

                                              1. 2

                                                You can think of ansible as the equivalent to nixops in the realm of stateful system management. Both provide secrets management, orchestration across multiple machines and varying degrees of infra as code. The main difference to nixops is that it works across operating system boundaries without remote builder setups.

                                                1. 2

                                                  The main difference to nixops is that it works across operating system boundaries

                                                  That’s what I’ve experienced in my (albeit limited) ansible experience. You can generally point it at an existing install and it’ll do the “right thing”.

                                                  without remote builder setups

                                                  Do you really need a remote builder for nixops? I’ve had good experience with local builds. Provided, you need to have a beefy enough build machine if things get complicated, but I guess that’s what the binary caches are for. Is that what you mean?

                                                  1. 1

                                                    Do you really need a remote builder for nixops?

                                                    I tried using it to provision a Linux box from a Darwin machine; cross-compilation is quite messy. (Also I’d recommend nixus, it’s far less annoying to operate than nixops!)

                                                2. 1

                                                  Depends on what your goals are for the homelab. In my case I like the chance to try to understand tools I use at work better at home.

                                                  Several years ago, my company was moving from Puppet to Ansible for our infrastructure management several years ago and I spent some weeks writing Ansible roles in different ways for each component of my homelab. It grew my skillset and I didn’t have to waste a lot of billable hours on learning a new tool.

                                                  Similarly with Kubernetes, which we’re currently implementing to host our web applications, I’ve been writing my own Dockerfiles and standing them up in a minikube instance at home to get a feel for the environment.

                                                  1. 1

                                                    It grew my skillset and I didn’t have to waste a lot of billable hours on learning a new tool.

                                                    Why is that a good thing? Are you expected to know everything at work?

                                                    1. 1

                                                      No? But it sure does make me a much more effective and valuable part of my team. And I like learning?

                                                      1. 1

                                                        If you’re billing hourly, usually yes.

                                                  1. 9

                                                    I unabashedly love it when things have “new” in their name that are 15 years old or older. This and newLISP are some favorite examples.

                                                    1. 8

                                                      “I went to New College at Oxford.”

                                                      “Oh, it’s new? When did it open?”

                                                      “…1379”

                                                      1. 6

                                                        It’s fascinating to me that we don’t actually know how old Oxford University is. The traditional ‘founding’ date of 1096 is actually just the first year we have records of teaching taking place.

                                                      2. 6

                                                        Or “yet another”, like YACC, when almost no one remembers what earlier compiler-compilers existed before it.

                                                        1. 3

                                                          Windows New Technology.

                                                        1. 3

                                                          Took me a bit to realize this was direct render m(something) and not digital restrictions management.

                                                          1. 2

                                                            From the man page:

                                                            NAME
                                                                 drm, inteldrm, radeondrm  Direct Rendering Manager device
                                                            
                                                            DESCRIPTION
                                                                 The drm driver provides support for hardware accelerated video using the
                                                                 Direct Rendering Infrastructure (DRI).  drm provides kernel support for
                                                                 DRI, and is used in conjunction with the X(7) DRI module.
                                                            
                                                            1. 1

                                                              I took a look at the linked post and didn’t get that either. I frankly did think it was Digital “Rights” Management too, and was vaguely puzzled by the reference to graphics cards, and Linux, but figured it had something to do with playing restricted video?

                                                            1. 1

                                                              Wow. I’ve been using hammerspoon for a few years, but today I learned about URLDispatcher. That’s going to save me so many browser tabs with Zoom meetings!

                                                              1. 2

                                                                this specific use case was my exact motivation for heading down this path.

                                                                1. 2

                                                                  I set it up yesterday and already it’s saved me whole minutes! Thanks for figuring out the chrome profile selection logic, that works like a charm (:

                                                                  1. 2

                                                                    minutes! pay it forward :-)

                                                              1. 2

                                                                I’ve paid for an account on bazqux.com for a long time now (nearly 10 years? Edit: 7 years.), and it’s quite nice. The web interface is very google reader-y, and it speaks the api that most gui readers speak for syncing. Can recommend.

                                                                1. 6

                                                                  When we tested mdadm and ext4, we didn’t really use the entire disk—we created a 1TiB partition at the head of each disk and used those 1TiB partitions. We also had to invoke arcane arguments—mkfs.ext4 -E lazy_itable_init=0,lazy_journal_init=0—to avoid ext4’s preallocation from contaminating our results.

                                                                  Using these relatively small partitions instead of the entire disks was a practical necessity, since ext4 needs to grovel over the entire created filesystem and disperse preallocated metadata blocks throughout. If we had used the full disks, the usable space on the eight-disk RAID6 topology would have been roughly 65TiB—and it would have taken several hours to format, with similar agonizing waits for every topology tested.

                                                                  So they tested a configuration that nobody’s going to be actually … running. I guess that’s part for the course with online performance testing magazines, but wow.

                                                                  1. 2

                                                                    part for the course

                                                                    The expression is “par for the course”. It comes from golf.

                                                                    https://www.collinsdictionary.com/us/dictionary/english/par-for-the-course

                                                                    1. 1

                                                                      Agreed. I’ll select & copy your message so that maybe iOS autocorrect can learn from it.

                                                                  1. 1

                                                                    What else people use nowadays? Macaroon?

                                                                    1. 4

                                                                      I don’t know much about it, and don’t have any experience with JWT either, but I’ve heard of this:

                                                                      https://github.com/paragonie/paseto

                                                                      1. 3

                                                                        I’ve used paseto in the recent past, and it was extremely easy to use & achieve good results with. Would strongly recommend on that alone. My crypto friends all seem to like it, too, so that seems like a winner.

                                                                    1. 6

                                                                      About a decade and a half ago, I worked on supporting people in using CLIM, a GUI interaction library for Common Lisp. People using it were mostly scientists, and the most prominent tool built with it was a massive tool suite to visualize genes and their associated research material. One of the test cases had me downloading the genome for Anthrax, which at the time I felt was the most metal thing I’d ever done or would ever do… so far, that’s remained true.

                                                                      1. 3

                                                                        This is a fun story & seems right. It ties in nicely with this text by Darius Kazemi, written much later, on running small fediverse instances: https://runyourown.social/