Skip to content

Instantly share code, notes, and snippets.

View kl0tl's full-sized avatar

Cyril Sobierajewicz kl0tl

View GitHub Profile
@kl0tl
kl0tl / Main.purs
Last active September 8, 2020 09:29 — forked from JordanMartinez/Main.purs
ArrayZipper's smallest Extend implementation
module Main where
import Prelude
import Control.Comonad (class Comonad)
import Control.Extend (class Extend)
import Control.Monad.Gen (chooseInt)
import Data.Array (length, mapWithIndex, unsafeIndex)
import Data.Array.NonEmpty (toArray)
import Effect (Effect)
import sublime, sublime_plugin
# Takes an array of commands (same as those you'd provide to a key binding) with
# an optional context (defaults to view commands) & runs each command in order.
# Valid contexts are 'text', 'window', and 'app' for running a TextCommand,
# WindowCommands, or ApplicationCommand respectively.
class RunMultipleCommandsCommand(sublime_plugin.TextCommand):
def exec_command(self, command):
if not 'command' in command: