Skip to content

Instantly share code, notes, and snippets.

View lispstudent's full-sized avatar

Lisp student lispstudent

View GitHub Profile
@baetheus
baetheus / README.md
Last active December 2, 2024 11:51
SmartOS Single IP with NAT using VLAN

WARNING

These intructions might work, but they need a bit of attention. I've been reading through ipf and smf documentation and have found a few ways to improve this process. When I have time I'll add that information here, until then, be sure to look into the ipf settings if you're having issues with routing. Good luck!

Foreword

This is a modified version of sjorge's instructions for Single IP with NAT. Those instructions can be found here: https://docu.blackdot.be/snipets/solaris/smartos-nat

The primary difference is that this version does not rely on etherstubs for internal switching, but instead uses a vlan configuration. The benefits of this method over using etherstubs are:

  1. Project Fifo (project-fifo.net) can create vms and zones with vlans, but does not currently have etherstub support.
  2. Vlan switching is supposedly more efficient than creating an etherstub to handle switching. I have not tested this statement.
@tanakahx
tanakahx / update-md.lisp
Created August 29, 2014 16:17
Update date and time in a octopress's markdown file.
;;; Update date and time in a octopress's markdown file.
;;; This script also updates date in the file name.
(load "~/quicklisp/setup.lisp")
(ql:quickload :cl-ppcre)
;; Temporary file created in the current directory
(defparameter *temp-filename* "temp.txt")
(defun time-string (&optional detail)
@chaitanyagupta
chaitanyagupta / _reader-macros.md
Last active July 4, 2025 22:26
Reader Macros in Common Lisp

Reader Macros in Common Lisp

This post also appears on lisper.in.

Reader macros are perhaps not as famous as ordinary macros. While macros are a great way to create your own DSL, reader macros provide even greater flexibility by allowing you to create entirely new syntax on top of Lisp.

Paul Graham explains them very well in [On Lisp][] (Chapter 17, Read-Macros):

The three big moments in a Lisp expression's life are read-time, compile-time, and runtime. Functions are in control at runtime. Macros give us a chance to perform transformations on programs at compile-time. ...read-macros... do their work at read-time.

@intafon
intafon / svndiff2html
Last active November 4, 2021 10:00
svndiff2html runs svn diff on the current directory path and outputs a formatted HTML file to provide easier legibility.
#!/bin/bash
# svndiff2html runs svn diff on the current directory path and outputs a
# formatted HTML file to provide easier legibility.
diff="";
out="";
html="";
args="";
@jahewson
jahewson / smartos-on-a-budget.sh
Last active March 9, 2024 07:27
Installing and Configuring SmartOS on a budget server (with a /29)
# Licensed under CC BY 3.0 http://creativecommons.org/licenses/by/3.0/
# Derived works must attribute https://gist.github.com/4492300 at the beginning, and the date.
##################################################################
Installing and Configuring SmartOS on a budget server (with a /29)
##################################################################
# if you find this gist useful, please star it
# please be aware that budget hosting companies usually cut corners somewhere,