Helge Heß · @helge
538 followers · 664 posts · Server mastodon.social

: Runestone for Mac looks really nice already, great job @simonbs! Probably going to use it instead of CodeEditor in Shaper and Enlighter. github.com/simonbs/Runestone

#lunchbreakfoss

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

@binarytango @kotaro Also maybe run things in Docker, I use Hypriot on Raspi's and love it. Keys and such can be configured via cloud config before flashing an image. blog.hypriot.com/getting-start

#lunchbreakfoss

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

Today’s thing isn’t really a FOSS project per se, more like a standard: “Mustache”. A very simple templating language with implementation for literally any language.
It just has like `{{var}}`, `{{^var}}` and `{{>sub template}}`, but can model loops, conditions and even sub-templates using that. It’s my go-to for quick and simple things.
A small implementation that supports attributed strings and dynamicCallable: github.com/AlwaysRightInstitut
mustache.github.io

#lunchbreakfoss #swiftlang

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

OK, another lazy one “Apache”, the No 1 WebServer. Used the 1.x line from the start and the current 2.x line brought great advancements. Considered a “fat” server once, it is actually smaller than your typical server lib today 🤓
Apache is highly capable and extremely solid. Use it when you actually serve things, for proxies nginx is the better choice. (nginx is a NIO server, it's more complicated, but Apache is technically a thread per connection setup).
httpd.apache.org

#lunchbreakfoss

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

One can just install from the sources or using Homebrew, but another very easy and convenient way is the “Postgres.app”. Which I’ve been using for years, and it is in fact open source!

It bundles up the server as a app, including the necessary login/menubar items. Recommended, very quick way to get started!
It is *not* a database browser/frontend though, it manages the server.
postgresapp.com/de/

#lunchbreakfoss #postgresql #macos

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

A lazy one today: “PostgreSQL”. is a relational database (an RDBMS) with tons of extra features, from JSON to full text search to PL/Swift.

We started to support it in OpenGroupware around version 6.5 - at that time it was really bad. I think only w/ the 8.x versions (maybe late 7.x revs) it started to be the plain awesomeness it is today.
Funny side note: The server binary of that “big db server” is just about 7MB!
postgresql.org

#lunchbreakfoss #postgresql

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

So how can a dev access/work-with ? The raw API IMO goes a long way and is often sufficient (and reasonably convenient). If a little more is needed, I have my own “Lighter” project, but today is about another one: “GRBD”.

I use it in the SPMCatalog app’s backend. It has great documentation and many of the design decisions align w/ me. From the regular Swift DB libs it is also the fastest I tried (though not as fast as Lighter 😜).
github.com/groue/GRDB.swift/bl

#lunchbreakfoss #swiftlang #sqlite

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

Not sure I should mention “the obvious” big FOSS projects, but since it IMO is still way underused by developers: SQLite. The embedded SQL database. Even just the plain API is easy to use!

If you don’t want SQL, just store JSON snippets in it, still a useful container for data with proper locking and all kinds of other safeguards you probably do wrong otherwise.

I’d like to especially point out “SQLite as an application file format”: sqlite.org/appfileformat.html

#lunchbreakfoss #swiftlang

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

Something a little different today: “Graphite”. This project has a set of tools built around a (Python) time series database (called “Carbon”). Including some old-school looking but powerful graphing tools.
I use it to store sensor data in my home automation system (). It was really easy to setup and runs for years w/ very little maintenance, though things like Grafana/TimescaleDB might be better options today. I like it though.
graphiteapp.org

#lunchbreakfoss #homematic

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

“Runestone” isn't a project I actually use just yet, but which I find really interesting in the context of yesterdays Highlight.js (and for my apps as a potential replacement for my “CodeEditor” project based on HJS).
Runestone is an editor w/ syntax highlighting based on that “tree sitter” stuff, written in . One of the biggest drawbacks for me is that it only supports , not .
github.com/simonbs/runestone

#lunchbreakfoss #swiftlang #uikit #appkit

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

“Highlighter.js” is another project that might be useful for Mastodon client coders. It is a JavaScript library for highlighting source code. There seem to be better technologies for this (RuneStone, etc), but a major advantage of Highlighter.js is that it supports a huge array of languages.
I use it in Shrugs.app to highlight source snippets using sth similar to Highlightr. Overhead for hosting the JS is ~5MB RAM.
github.com/raspu/Highlightr
highlightjs.org

#lunchbreakfoss #swiftlang

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

The new year is about emotions? I hope not, but if so, there is “emoji-data”, another great project. It contains all kinds of metadata for as JSON (e.g. short names, Unicode code points and more).
 Using it in Shrugs.app to parse and complete Emoji in messages and in the Emoji picker as well. I bet this might be useful for all the Mastodon client builders.

Funny side-note: Project is by a Slack co-founder!
github.com/iamcal/emoji-data

#lunchbreakfoss #emoji

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

Another nice tool that fits into the line (and was mentioned already) is “xmlstarlet”, a set of tools to query and edit files.
“xmlstarlet” is somewhat similar to “jq”, but for XML instead of JSON. Handy if you have to read and modify XML files from within shell scripts in a reliable way (i.e. w/o a regex mess 🙃).
I use it in mod_swift (to patch the Xcode scheme XML) and also in the scraper backing the SwiftPM Catalog application.
xmlstar.sourceforge.net/doc/UG

#lunchbreakfoss #xml

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

This week ended up being more like a libs for the web 🕸 thing. So one more of those: “libcurl” and its companion tool “curl”. Must haves for every developer. It is one of those software projects that have an extremely high overall quality. It used to be used for the URLSession implementation of the Linux Foundation lib, but I suppose that might go away 🥲
curl.se/libcurl/

#lunchbreakfoss #c #serversideswift #swiftlang

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

Using libxml2 from yesterdays edition one can actually parse , which is quite cool. The parser however is not very tolerant, i.e. doesn’t deal well with what real world HTML programmers tend to create. And how do you fixup b0rked HTML? With the “HTML Tidy” tool of course! One of those things which just do one thing, but that very well.
But the best thing is that this tool also comes as a library: “libtidy”.
html-tidy.org/developer/

#lunchbreakfoss #html #c

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

Yesterday was Expat day, today is “libxml2” (/libxslt) day. This is also a parsing library, but with way more features, e.g. XPath and XSLT. It also has a SAX API, but I’d go Expat for that, use “libxml2” when you need a “DOM” and operate on that. A cool thing is that libxml2 can also parse reasonably valid HTML, which can often be handy! Included on iOS/macOS.
SOPE comes w/ wrappers/drivers for libxml2: sope.opengroupware.org/en/sope
libxml docs: gitlab.gnome.org/GNOME/libxml2

#objc #lunchbreakfoss #c #xml

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

Let’s make an in-between week w/ old school projects that rock ☣️ Something I’ve been using for 20+? years is libexpat. It is a very compact SAX based parser written in C. It just does SAX, but is very good at that and carries no bloat. Can be a good choice for your daily XML parsing needs 👴 Looks like I once did a small Swift wrapper: github.com/helje5/SwiftyExpat
libexpat.github.io

#lunchbreakfoss #c #foss #xml

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

A late one today, but a very useful one: „SOTO“. It provides Swift APIs for all the various services. I played with it for a while when trying to build a small macOS frontend for AWS. Looked really good!
github.com/soto-project/soto

#lunchbreakfoss #aws

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

Today’s project is an Electron app, I’m very sorry. I want to rewrite that in for a very long time - well, I started multiple times - and eventually will finish that. In the meantime that non-native app is really useful for people running a home automation setup.
github.com/hobbyquaker/homemat

#lunchbreakfoss #swiftui #homematic

Last updated 2 years ago

Helge Heß · @helge
532 followers · 625 posts · Server mastodon.social

In one app (never released) I wanted to show a network of devices interconnected by lines w/ various information about the connections. TBH I had/have no idea how to distribute objects in a view in a useful manner 🤷‍♀️

But I found a nice looking JS library for just that, and the coolness of that starts with the name: “Graph Dracula” 🧛‍♂️
Very nice lib, actually started to port the parts I need to .
graphdracula.net
github.com/helje5/Dracula

#lunchbreakfoss #swiftlang

Last updated 2 years ago