Skip to content

Instantly share code, notes, and snippets.

View cmoore's full-sized avatar
🆑

Clint Moore cmoore

🆑
View GitHub Profile
(ql:quickload '(:jsown
:json-mop))
(defpackage :geojson
(:use :cl
:json-mop))
(in-package :geojson)
<input type="hidden" name="pricescouter-price" value="40.63">
<input type="hidden" name="pricescouter-unique" value="4B1956H-STD">
<input type="hidden" name="pricescouter-manufacturer" value="Acme">
<!--
Optimally, "pricescouter-unique" will be a SKU, part number, or
model number. The more specific, the better.
-->
<script src="//pricescouter.net/pricescouter.js">
<div style="display:none;" id="pricescouter-pricetable"></div>
@cmoore
cmoore / grovel.lisp
Created October 7, 2017 03:37
grovel.lisp
(in-package :efl)
#+ (or freebsd darwin)
(progn
(include "time.h")
(include "sys/time.h"))
(cc-flags #+freebsd "-I/usr/local/include -I/usr/local/include/elementary-1 -I/usr/local/include/efl-1 -I/usr/local/include/eina-1/eina -I/usr/local/include/eina-1 -I/usr/local/include/eet-1 -I/usr/local/include/emile-1 -I/usr/local/include/evas-1 -I/usr/local/include/eo-1 -I/usr/local/include/ecore-1 -I/usr/local/include/ecore-evas-1 -I/usr/local/include/ecore-con-1 -I/usr/local/include/ecore-file-1 -I/usr/local/include/ecore-imf-1 -I/usr/local/include/ecore-input-1 -I/usr/local/include/ecore-x-1 -I/usr/local/include/edje-1 -I/usr/local/include/eldbus-1 -I/usr/local/include/efreet-1 -I/usr/local/include/ethumb-1 -I/usr/local/include/ethumb-client-1")
@cmoore
cmoore / buildlog.txt
Created October 2, 2017 20:39
Building SBCL 1.4.0 on FreeBSD
rm -f *~ *.bak *.orig \#*\# .\#* texput.log *.fasl
rm -rf sbcl asdf version "docstrings/"
rm -f sbcl.html asdf.html
rm -f contrib-docs.texi-temp
rm -f package-locks.texi-temp
rm -f variables.texinfo
rm -f sbcl.ps asdf.ps sbcl.pdf asdf.pdf html-stamp tempfiles-stamp
rm -f asdf.aux asdf.cp asdf.cps asdf.fn asdf.fns asdf.ky asdf.log asdf.pg asdf.toc asdf.tp asdf.tps asdf.vr asdf.vrs sbcl.aux sbcl.cp sbcl.cps sbcl.fn sbcl.fns sbcl.ky sbcl.log sbcl.pg sbcl.toc sbcl.tp sbcl.tps sbcl.vr sbcl.vrs
rm -f sbcl.info sbcl.info-* asdf.info
rm -rf *.include *.info *.pdf *~ *.cp *.fn *.ky *.log *.pg *.toc \
@cmoore
cmoore / spreadsheet.st
Last active August 15, 2017 21:48
GeneralScrollPane is not scolling.
lx := ZnClient new.
json_data := Array with:
(NeoJSONReader fromString: (lx get: 'https://api.github.com/users/cmoore')).
sheet := SpreadsheetGridMorph new
hResizing: #spaceFill;
vResizing: #spaceFill;
yourself.
module Main where
import qualified Data.ByteString.Char8 as B
import Data.Tree.NTree.TypeDefs
import Data.Maybe
import Text.XML.HXT.XPath
import Text.XML.HXT.Core
import Control.Monad
import Control.Monad.Trans
@cmoore
cmoore / react.lisp
Last active December 20, 2015 02:00
An example of the syntax.
(define-easy-handler (react-stuff :uri "/react/all") ()
(send-react
(defvar panel (defreact
(json display-name "Panel"
component-will-mount (lambda ()
;; (->) is (ps:chain) and (.>) bind()s 'this' to the block.
(something-with-a-callback (.> (lambda (x) (-> this (do-something)))))
render (lambda ()
(rce "div" (json class-name "col-md-6")
(rce "div" (json class-name "panel panel-default panel-borders")
@cmoore
cmoore / servicle.lisp
Last active December 14, 2015 15:19
A quickie serve-the-current-directory script.
(ql:quickload 'cl-fad)
(ql:quickload 'hunchentoot)
(defun serve-this (args)
(declare (ignore args))
(hunchentoot:start (make-instance 'hunchentoot:easy-acceptor
:document-root (probe-file #P".")
:port 4040))
(read-char *standard-input*)