Programming Leftovers
-
Bastian Venthur: dotenv-cli update
Thanks to Nicholas Guriev, dotenv-cli now uses
exec
instead ofpopen
to create the new process onPOSIX
systems. -
Steinar H. Gunderson: The bestest sine function, redux
-
Dirk Eddelbuettel: RcppAnnoy 0.0.21 on CRAN: Upstream Update
Another minor maintenance release, now at version 0.0.20, of RcppAnnoy has arrived on CRAN.
-
Using git mailmap when names change (or you mess up your email)
In other applications, you can just change your name. In git, the history is meant to be immutable, so a record of old names is just... there. You could rewrite history, but in a team setting that sort of rebasing isn't really tenable. You just cannot stop the world long enough to make it happen.
Fortunately, we can paper over it by using git mailmap1. This lets you replace the name and email addresses on commits with the correct ones. It's pretty straightforward.
-
What's the largest possible PNG?
However, PNGs have no maximum file size. You can embed an infinite amount of metadata in PNGs—even a 1×1 image could be terabytes large if it has enough metadata inside.
-
Myths About ORMs
Object-relational mapping (ORM) libraries are scattered about millions of code repositories. They promise to bridge the gap between a relational database and an object-oriented programming language.
Instead of writing a SQL query like `SELECT * from users where id = 1`, you would define a User type with some special annotations and then write something like `user = users.select().where(“id = ?”, id)`. Some other features they might provide: type safety, connection management, or a migration framework.
But using an ORM is controversial. Some developers swear by them, while others avoid them altogether. Some myths about ORMs.