Live data from Hacker News

Ask HN: What are some tools / libraries you built yourself?

news.ycombinator.com

181–190 of 617 posts

Re: Ask HN: What are some tools / libraries you built yourself?

#181
A while back, I built a sync library for iOS storage CloudKit (Apple’s iCloud storage system)! It features offline queuing, smart merge/deduplication, and uses NTP timestamps to make sure offline/online merges are handled reliably. It took quite a bit of time to get right, and is probably one of the projects that has helped me grow the most (technically) as an engineer.

- I built it because at the time, sync for iOS was a mess: Apple’s original CoreData iCloud sync was very buggy and often failed to sync. An open source alternative seemed nice but poorly maintained, and I wasn’t completely on board with the overall architecture of it. A paid library was great but also quite complex and I had no control over the direction, features, and longevity.

- Apple released their own alternative recently, although it’s only available on newer iOS versions. Additionally, I’m not in control of the CloudKit data schema, and I don’t have the ability to add more complex sync features if needed.

- underlying all of this: the need for control, reliability, and customizability.

So, I spent a few weeks writing my own system. It works well and despite a few hiccups that I’ve resolved, it currently provides reliable, seamless sync for an app with millions of downloads.

- My library is quite generic but I never open sourced it. It would be a nice contribution to the open source community, but I’m not sure I have time to consistently maintain it or review pull requests. I’ve considered it at times, but it’s just never been a priority.

- If sync ever goes wrong, I’m able to debug it and understand exactly what the problem is.

- I can add features any time I like. I plan to do so soon to support a few things that even Apple’s new solution might not encompass.

There are quite a few downsides to it too:

- I need to maintain it myself

- It probably has had less testing than something like Apple’s new solution

- I’ve occasionally shipped a small sync bug, primarily due to lack of ability to test at scale

Overall I think it was worth it, especially given that Apple’s new solution wasn’t available at the time. I learnt a lot; building a generic framework is a great way to grow technically.

If I had to make the same decision again today, I’d heavily consider Apple’s new solution instead, although I’d only choose it if I was confident that it is much more reliable than the prior option they provided.

Re: Ask HN: What are some tools / libraries you built yourself?

#182
Repoint, a thingy for checking out and versioning your source code dependencies - for situations where you don't have a good language-specific source package manager to hand.

https://thebreakfastpost.com/2018/05/18/repoint-a-manager-fo...

https://github.com/cannam/repoint

I wrote this because, as is normal, I was slightly dissatisfied with all the options I could find that would work with the language and hosting combination I happened to be using. I use it for a number of projects now and I have to say that it's really quite good.

It's written in Standard ML, which might tickle a few HN readers.

Re: Ask HN: What are some tools / libraries you built yourself?

#183
I built a safe PostgreSQL driver for node from scratch with zero dependencies in about 1200 lines. I did this mostly because of the plumbing required to make the goto node driver tolerable to work with. In the process I made it 4-5 times faster as well. https://github.com/porsager/postgres

Re: Ask HN: What are some tools / libraries you built yourself?

#184
I have 112 mostly-maintained released project listed on https://github.com/simonw/simonw/blob/main/releases.md now - most of which are tools for loading data into SQLite database files (a surprisingly under-served use-case given how ubiquitous SQLite is) and plugins for my https://datasette.io/ project for reading data back out of SQLite again.

I realized a few years ago that SQLite was the perfect tool for doing data analysis at the small-data scale, where small data is less that 10GB which is pretty much everything you might want to analyze - especially for personal projects.

So I've been building tools to fill that niche!

Re: Ask HN: What are some tools / libraries you built yourself?

#185
Most of my blog posts (at chriswarbo.net ) are about programming, so I wanted a way to run code embedded in markdown, and to include the results in the rendered document. I wrote a couple of scripts to do this via pandoc:

- https://hackage.haskell.org/package/panpipe

- https://hackage.haskell.org/package/panhandle

They're described in more detail at http://chriswarbo.net/projects/activecode

Re: Ask HN: What are some tools / libraries you built yourself?

#186
I build a logging library for Go, because I couldn't find one that logs to stdout AND stderr. If you used a logging lib on GCP for example, all log output went into the same pile of junk and it was hard to find "real" errors: https://github.com/emvi/logbuch

Then there is "null", also because I couldn't find one that got both, marshalling to JSON and be able to store null values in db: https://github.com/emvi/null

And finally, our "flagship" open-source project Pirsch, an embedded library for web analytics: https://github.com/pirsch-analytics/pirsch

Re: Ask HN: What are some tools / libraries you built yourself?

#187
post #135

I've made a few things: - Zola ( https://github.com/getzola/zola ) a SSG that works like I wanted and had a template engine close to Jinja2. I was using Hugo at the time but can't stand Golang template engine (imagine my sadness recently when I realised what Helm Charts are using...) - Tera ( https://github.com/keats/tera ): a template engine pretty close to Jinja2/Django templates - at the time it was made only Hand…

The last software team I was on used Zola for a lot of our internal documentation publishing. It worked great and we were really happy with it!

Re: Ask HN: What are some tools / libraries you built yourself?

#188
Dbmate: https://github.com/amacneil/dbmate

I found most database migration tools tried to be too smart (I'm not a fan of automatic migrations), were too tightly integrated with specific languages or frameworks, or didn't support basic developer workflow pleasantries such as dropping and recreating the database.

I created a simple single binary migration tool that runs migrations (sql files), and keeps track of applied migrations in a table (inspired by Active Record migrations). Dbmate works with any language or framework, and generally tries to be useful while staying out of your way.

Comparison against other tools here: https://github.com/amacneil/dbmate#alternatives

Re: Ask HN: What are some tools / libraries you built yourself?

#190
I made a few things for my personal use that are used often that I'm quite pleased with, in no particular order:

1. Wallpaper adhesive (https://github.com/jacobmischka/wallpaper-adhesive), an electron app I made ages ago when electron was still relatively new that creates spanned wallpapers for multimonitor setups based on your displays' resolutions. I use it every time I change my wallpapers, every month or so.

2. ics-merger (https://github.com/jacobmischka/ics-merger), a suite of tools including a webapp to merge separate calendar feeds together into a grouped feed, with possible subgroups. One can navigate through the subgroups, see event details, and subscribe to a merged feed, among other similar things. I made it for work, where it's used as the master departmental calendar feed. The webapp heavily relies on fullcalendar, but the added features aren't trivial.

3. Tea whistle (https://github.com/jacobmischka/tea-whistle), my second simple microcontroller project I made for my mother for her birthday because her teapot doesn't have a whistle so she kept accidentally boiling it over. It just polls the attached thermometer and beeps when the temperature is over boiling. She uses it every day and says she hasn't boiled it over once since!

4. inmytime.zone (https://github.com/jacobmischka/inmytime.zone), a simple webapp that allows you to create a URL that converts the time you give it into the local timezone of whoever is viewing it. It's effectively just a clone of https://everytimezone.com/ or one of the many other similar tools, but much less busy and without ads. I let the domain expire a few months ago, so it's not currently available, but I just renewed it so it should be again once the domain servers propagate. Edit: Seems to be back up for me now, at least.

5. Gym notebook (https://github.com/jacobmischka/gym_notebook), a flutter app I made when flutter was still quite new to track my workouts using firebase for storage. It's quite rough around the edges, fetches data from the network way more often than necessary, and needs a few bugfixes and could use a bit of work, but it's still good enough for me to use it 4-5 times per week.

Post reply on HN