Archive

Archive for May, 2017

Robomongo

Robomongo is a native GUI client for MongoDB. So far I’ve used RockMongo, which was perfect for me, but it’s PHP-based and quite hard to install. Also, it seems to be abandoned, the last commit was in 2015. It’s a pity…

Robomongo is simple. Just download, decompress, and launch. It’s free and multi-platform.

Advertisements
Categories: mongodb Tags: , , ,

JSON Path

May 20, 2017 1 comment

I wrote a command-line program that outputs the full path of every key / value in a JSON file.

Example

$ ./json_path.py sample.json
root.a => 1
root.b.c => 2
root.b.friends[0].best => Alice
root.b.friends[1].second => Bob
root.b.friends[2][0] => 5
root.b.friends[2][1] => 6
root.b.friends[2][2] => 7
root.b.friends[3][0].one => 1
root.b.friends[3][1].two => 2

More information at the project’s github page.

Categories: bash, python Tags: ,

streamlink

Streamlink is a command-line utility that allows you to watch online video streams in popular video players, such as VLC, MPlayer or mpv.

(Under Manjaro it’s installable with yaourt.)

Example:

$ streamlink twitch.tv/sscait 
[cli][info] Found matching plugin twitch for URL twitch.tv/sscait
Available streams: 720p_alt, audio_only, 160p (worst), 360p, 480p, 720p (best)

$ streamlink twitch.tv/sscait best

If you just want to listen to it, select “audio_only” instead of “best”. It has lots of options, see the man for more info. For scripting, there is also a “-j” switch to produce a JSON output instead of normal text.

When is it useful? For instance you have a favourite channel that is streaming right now, but you don’t want to open it in the browser. Just launch it from the command-line and watch it in VLC. Or, if it’s a talk show, you just want to listen to it (see “audio_only”).

Categories: bash Tags: , , ,

sending e-mails from your app.

If you want to send e-mails from your application, check out https://www.mailgun.com/. You can register for free and with your free account you can also send a good number of e-mails. And if you pay for it, you can send thousands of mails if you want. Their service can be used from Bash, Python, PHP, etc.

On my VPS I used a command-line solution (see here) that sends e-mails with sendmail. Unfortunately, Gmail treats these mails as spam, so it’s not appropriate for sending messages to other people. Mailgun is a better solution.

Categories: api, bash, python Tags: ,

fonts for programming

See https://github.com/powerline/fonts. It also has an installer script. The font Hack works very well for me.

Categories: linux Tags: