Skip to content

Instantly share code, notes, and snippets.


Amjith Ramanujam amjith

View GitHub Profile
amjith /
Created Jun 18, 2020
Datasette plugin for updating db and metadata
from datasette import hookimpl
from datasette.database import Database
from starlette.responses import HTMLResponse
from starlette.routing import Router, Route
from starlette.endpoints import HTTPEndpoint
def asgi_wrapper(datasette):
dirty=`git status --porcelain -uno | sed s/^...//`
last_modified=`git show --pretty="format:" --name-only HEAD`
if [ -n "$dirty" ]; then
echo $dirty
echo $last_modified
amjith / gitconfig
Last active Feb 21, 2018
View gitconfig
open = !vim ``
amjith / precommit
Created Aug 16, 2017
precommit hook
View precommit
pep8radius master --in-place
git diff --cached --name-only | egrep '\.py$'| xargs -l git add
View log.json
{"message":"Plugin failed to load","stack":["Error: Cannot find module 'clone'"," at Module._resolveFilename (module.js:455:15)"," at Function.Module._resolveFilename (/Applications/"," at Function.Module._load (module.js:403:25)"," at Module.require (module.js:483:17)"," at require (internal/module.js:20:19)"," at Object.<anonymous> (/Users/amjith/.zazu/plugins/tinytacoteam/zazu-clipboard/node_modules/color/index.js:2:13)"," at Module._compile (module.js:556:32)"," at Module._extensions..js (module.js:565:10)"," at Object.require.extensions.(anonymous function) [as .js] (/Applications/"," at Module.load (module.js:473:32)"],"plugin":"tinytacoteam/zazu-clipboard","block":"searcher","level":"error","timestamp":"2017-01-11T22:27:08.841Z"}
{"input":",v ","respondsTo":null,"plugin":"tinytacoteam/zazu-chrome-bookmarks","block":


## Core vision

A fully extensible and open source app launcher for hackers, creators and dabblers. It comes with sane defaults to make it useful out of the box. But everything can be changed to fit your needs. Don't let others tell you the best way to be productive, configure it to be perfect for you.

## How do you compare to alternatives?

Zazu is the first launcher to treat plugins as first class citizens. Even the app finder is built as a plugin which can be replaced (if desired). This means plugins are designed as natural extensions of Zazu and they don't require a special trigger such as '/' or ','. This allows a more intuitive desgin that is doesn't hamper discoverability.

View zazu.plugin.log
ERROR: [23:00:40][tinytacoteam/zazu-clipboard:clip]
Script failed
"error": {},
"query": ""
ERROR: [23:00:40][tinytacoteam/zazu-clipboard:clip]
Script failed

Keybase proof

I hereby claim:

  • I am amjith on github.
  • I am amjith ( on keybase.
  • I have a public key ASCybq0HEjJam9F4HCBqN8nVKGXLojzGGReK9y6p4vTLUgo

To claim this, I am signing this object:

amjith /
Last active Nov 24, 2017
Template for creating awesome REPLs with prompt-toolkit
from prompt_toolkit import prompt
from prompt_toolkit.history import FileHistory
from prompt_toolkit.contrib.completers import WordCompleter
from pygments.lexers.sql import SqlLexer
import sqlite3
history = FileHistory('history.txt')
completer = WordCompleter(['select', 'insert', 'delete', 'drop', 'from'])
connection = sqlite3.connect(':memory:')
amjith / pong.elm
Created Jun 16, 2016
Using focus in elm 0.17
View pong.elm
module Pong exposing (..)
import Element exposing (..)
import Collage exposing (..)
import Color exposing (..)
import Keyboard exposing (KeyCode)
import AnimationFrame
import Time exposing (Time)
import Html exposing (Html, text)
import Html.App as Html
You can’t perform that action at this time.