Skip to content

Instantly share code, notes, and snippets.

View hanmoi-choi's full-sized avatar

dchoi hanmoi-choi

  • Square
  • Melbourne
View GitHub Profile
@ekaschalk
ekaschalk / esh-custom.el
Created June 24, 2017 04:39
Customizing your emacs shell.
(require 'dash)
(require 's)
(defmacro with-face (STR &rest PROPS)
"Return STR propertized with PROPS."
`(propertize ,STR 'face (list ,@PROPS)))
(defmacro esh-section (NAME ICON FORM &rest PROPS)
"Build eshell section NAME with ICON prepended to evaled FORM with PROPS."
`(setq ,NAME
@Sharpie
Sharpie / Vagrantfile
Last active September 22, 2022 01:16
A simple Vagrantfile for spinning up a master-agent pair.
# -*- mode: ruby -*-
# vi: set ft=ruby :
# This configuration requires Vagrant 1.5 or newer and two plugins:
#
# vagrant plugin install vagrant-hosts ~> 2.1.4
# vagrant plugin install vagrant-auto_network ~> 1.0.0
#
# After installation, the following steps will spin up a master and agent that
# can communicate with each other:
@DinoChiesa
DinoChiesa / xmlpretty.el
Last active July 23, 2018 08:23
elisp for pretty-printing XML from within emacs
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; pretty print xml in region
;; http://stackoverflow.com/a/5198243/48082
(defun dino-xml-pretty-print-region (begin end)
"Pretty format XML markup in region. You need to have nxml-mode
http://www.emacswiki.org/cgi-bin/wiki/NxmlMode installed to do
this. The function inserts linebreaks to separate tags that have
nothing but whitespace between them. It then indents the markup
by using nxml's indentation rules."
(interactive "r")
@tsabat
tsabat / zsh.md
Last active July 7, 2024 16:56
Getting oh-my-zsh to work in Ubuntu