• 0 Posts
  • 10 Comments
Joined 1 year ago
cake
Cake day: August 3rd, 2023

help-circle

  • is-number is a project by John Schlinkert. John has a background in sales and marketing before he became an open source programmer and started creating these types of single function packages. So far he has about 1400 projects. Not all of them are this small, though many are.

    He builds a lot of very basic functionality packages. Get the first n values from an array. Sort an array. Set a non-enumerable property on an object. Split a string. Get the length of the longest item in an array. Check if a path ends with some string. It goes on and on.

    If you browse through it’s not uncommon to find packages that do nothing but call another package of his. For example, is-valid-path provides a function to check if a windows path contains any invalid characters. The only thing it does is import and call another package, is-invalid-path, and inverses its output.

    He has a package called alphabet that only exports an array with all the letters of the alphabet. There’s a package that provides a list of phrases that could mean “yes.” He has a package (ansi-wrap) to wrap text in ANSI color escape codes, then he has separate packages to wrap text in every color name (ansi-red, ansi-cyan, etc).

    To me, 1400 projects is just an insane number, and it’s only possible because they are all so trivial. To me, it very much looks like the work of someone who cares a lot about pumping up his numbers and looking impressive. However the JavaScript world also extolled the virtues of these types of micro packages at some point so what do I know.



  • The numbers are different because the site doesn’t naively count every line but merges some as a single package. For example, at the very top of the Debian list we have 0ad, 0ad-data, 0ad-data-common. These are all counted as one single “package.”

    One might argue that doing the comparison in that way is more useful to an average user asking “which distribution has more software available.”




  • A git branch is just a pointer to a commit, it really doesn’t correspond to what we’d naturally think of as a branch in the context of a physical tree or even in a graph.

    But as the article points out, a commit includes all of its ancestors. Therefore pointing to a commit effectively is equivalent to a branch in the context of a tree.

    Some other version control systems like mercurial have both a branch in a more intuitive sense (commits have a branch as a bit of metadata), as well as pointers to commits (mercurial, for example, calls them bookmarks).

    I mean, git has bookmarks too, they’re called tags.


  • Mac users, and actually most laptop users, don’t give a shit about the things you mention. They buy it, use it for some 2-5 years, then sell it and get a new model. Upgrading hardware is way too complicated for most people. They don’t know or care what a BIOS is. It comes with the OS installed and that’s the only thing they would ever want. Turn it on, use Safari, outlook, and office 365, maybe some tool like Photoshop/Ableton/etc, that’s it.

    I mean iPhones are the same right? They lock down everything so it’s idiot proof and they control the environment exactly so they can maximise the smoothness of the experience.