The language server protocol was proposed by Microsoft as a way for different editors and development environments to share language analysis backends This post describes how to configure Emacs, lsp-mode and the palantir python-language-server for improved code intelligence when working on Python projects. (I’m planning a companion post for Emacs, C++ and the cquery language server.) Goal Before starting, it is motivating to see what we are working towards.
Phil Hagelberg recently won the Lisp Game Jam 2018 with his entry EXO_encounter 667. What I found most interesting however, was his interactive programming setup. He programmed his game in (and contributed new features to) a Lisp to Lua compiler called Fennel, and used the game programming library Löve. With Emacs and some Lua thread magic, *he was able to perform runtime changes and introspection to his live running game project*.
tmtxt-dired-async by Trần Xuân Trường is an unfortunately lesser known Emacs package which extends dired, the Emacs file manager, to be able to run rsync and other commands (zip, unzip, downloading) asynchronously. This means you can copy gigabytes of directories around whilst still happily continuing with all of your other tasks in the Emacs operating system. It has a feature where you can add any number of files from different locations into a wait list with C-c C-a, and then asynchronously rsync the whole wait list into a final destination directory with C-c C-v.
The official Arduino Desktop IDE is fantastic at what it was made for. After downloading, opening your first sketch (say, blink.ino) and flashing this to your connected Arduino hardware takes all of 3 seconds. However, once your sketches become a little more complex, a more sophisticated IDE with code navigation, documentation and context-sensitive completion can be a great help. Currently, one of the better solutions is the Arduino extension for Visual Studio Code.
I had to use the ITEAD Studio XBee shield v1.1 with an Arduino m0 (SAMD21) board, which is a 3.3V board, whereas the most common Arduinos are 5V. At the time of this writing, the shield’s website was not very clear on how exactly to set the jumpers (zone 5: “When operated in 3.3V, install the jumper” — which one?!), and the rest of the internet also did not seem to know.
As I was listening to the December 21 episode of the CPPCast, together with TWiML&AI my two most favourite podcasts, I couldn’t help but be a little bewildered by the number of times the guest used the word “like” during their interview. Most of these were examples of speech disfluency, or filler words, but I have to admit that they detracted somewhat from an otherwise interesting discourse. During another CPPCast episode which I recently listened to, the hosts coincidentally discussed the idea of making available transcriptions of the casts.
In order to add a GiST index on a Postgres database that could be used to accelerate trigram matches using the pg_trgm module and the special gist_trgm_ops operator, I had to code up a special Django Index Django will hopefully soon support custom index operators, but if you need the functionality right now, this example will do the trick. The special GiST index class looks like this: from django.contrib.postgres.indexes import GistIndex class GistIndexTrgrmOps(GistIndex): def create_sql(self, model, schema_editor): # - this Statement is instantiated by the _create_index_sql() # method of django.