One of the curious parts of not bieng super young, is that the list of public projects I worked on is quite long, for example a C++17 compatible quickfix lib, twitter client, media player, logo processor, todo tool, multi platform service wrapper, etc. They are all useless now.
This is a small list of recent projects that might be useful to others.
Texted is a database-less blogging platform where you can write your posts using markdown or HTML.
Many times, I had content in different formats or platforms and it was not simple to recover or render/read. From issues with MS Word documents depending on a closed source paid application to read, google docs and wordpress posts that were hard to export, I was tired of the mess. To make things worse, sometimes, a bad change in those documents (sometimes by mistake) made them irrecoverable.
All the posts and templates you see in this website are hosted in gitlab, meaning that all is versioned and no small mistakes can make me lose what I wrote.
Or, what is my workflow?
With that, I don't lose any content and I can even open the content in the gitlab repo and see the rendering before restarting
LuSH is a lua for shell scripts - embedded in a single binary, easy to share, to run everywhere
I love Bash. I have tons of bash scripts, they're run only on my machine. If I copy to other hosts, they never work properly because either the bash version is older or some of the shell utils are not available or are not the same version, etc. Surely there are many methods to solve this, but the scripts complexity just increase. In prative, they never work everywhere. I want to simplify my life, not the other way around.
My own solution for that is to be able to deploy, just by copying, all I need to run my scripts. My first idea was to build a portable bash version, but I still need to have many other utils, such as awk, cut, wc, etc. So, why not using a more powerful language? For that, one widely used, easy and that just works is LUA. I love its simplicity and powerful tables. Initially, where I am, this will be a portable LUA interpreter (without any dependencies, all static) and many lua scripts with helpers to make it easy for the scripts to call local binaries.
Why not Python?
Because I really don't like whitespace as block delimiter
Why not Ruby?
Because the runtime is big and not very portable.
Why not (whatever other language)?
Because I had to choose one. I got a super popular language as I don't want to be the eternal father of the project. I want something to solve my issues and not creating more. LUA has tons of scripts to do pretty much anything and most of them I just need to copy a lua file to a directory. Isn't it great?
A simple grep util for those lazy to remember many command line options.
Have you ever wanted to have grep filtering but showing the first line (for instance, when you run ps | grep)? Me too. So I created sgrep!
(Note the header os the ps command, line 0)
# Displays lines containing "pub struct" string in all .rs files in the local directory
sgrep -p "pub struct" *.rs
# Displays lines containing "#ifdef" or "#ifndef" in all *.c* and *.h* files
sgrep -p "#ifdef" -p "#ifndef" -f .c -f .h
# Display the top 1 line and filter for bash, case insensitive
ps -ef | sgrep -t 1 -i -p bash
Sometimes, when running commands with long long outputs, it's great to have some space between them.