This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const r = require('rethinkdb'); | |
const sampleSchema = { | |
name: 'mydb', | |
tables: [ | |
{ | |
name: 'users', | |
// Not really used but as a schema reference |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; -*- lexical-binding: t; -*- | |
(require 'dash) | |
(require 's) | |
(require 'smex) | |
(require 'promise) | |
(require 'stream) | |
(require 'transducer ) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(require 'dash) | |
(require 's) | |
(require 'f) | |
(defface fmc/completion-label-face '((t (:weight bold :height 1.1))) | |
"Label face") | |
(defface fmc/completion-delimiter-face '((t (:weight light :height 0.9))) | |
"Delimiter face") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defvar fn/prodigy-command-name-prefix "fmpv/" | |
"The prefix when creating binding prodigy view commands.") | |
(defun fn/prodigy-switch-to-process-buffer (service) | |
"Just an wrapper for said function with SERVICE." | |
(prodigy-switch-to-process-buffer service)) | |
(defun fn/prodigy-prepared-switch-to-process-buffer (service) | |
"Another wrapper to make specific functions for viewing SERVICE." | |
(lexical-let* ((service-name (plist-get service :name)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(require 'f) | |
(defconst fn/relative-same-node "." | |
"Represents the same node on a path.") | |
(defconst fn/relative-parent-node ".." | |
"Represents the parent node on a path.") | |
(defun fn/relative-parent-node-thunk (&rest args) | |
"Always returns `fn/relative-parent-node'." |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defcustom fn/w3m-video-executable "vlc" | |
"The executable that can run a network video stream.") | |
(defcustom fn/w3m-video-args | |
(list | |
;; This skews how the process is managed for vlc | |
;; "--one-instance" | |
;; "--play-and-exit" | |
) | |
"Extra arguments to run `fn/w3m-video-executable'") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defconst fn/haskell-file-extension ".hs" | |
"The de facto haskell file extension.") | |
(defun fn/add-haskell-file-extension (name) | |
"Add the extension of .hs to a file or buffer NAME." | |
(if (string/ends-with name fn/haskell-file-extension) | |
name (concat name fn/haskell-file-extension))) | |
(defvar fn/org-haskell-mode-hook nil | |
"Hook when buffer is haskellized.") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(with-eval-after-load 'projectile | |
(defconst fn/project-file ".project.el" | |
"Project configuration file") | |
(defconst fn/project-local-file ".project-locals.el" | |
"Project local setting file") | |
(defconst fn/project-init-files (list fn/project-file fn/project-local-file) | |
"Project init files") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(with-eval-after-load 'projectile | |
(defconst fn/project-file ".project.el" | |
"Project configuration file") | |
(defconst fn/project-local-file ".project-locals.el" | |
"Project local setting file") | |
(defconst fn/project-init-files (list fn/project-file fn/project-local-file) | |
"Project init files") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun fn/orgtbl-to-yaml (table params) | |
"Convert an org table to yaml." | |
(lexical-let ((headers | |
(mapcar | |
(lambda (header) | |
(replace-regexp-in-string | |
" " "-" | |
(downcase header))) | |
(car table))) | |
(zip |
OlderNewer