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
;;;; Load some utilities | |
;;; ... typically this would go in our ASDF system file. | |
;;; in which case you wouldn't need the eval when | |
(eval-when (:compile-toplevel :load-toplevel :execute) | |
(ql:quickload "cl-interpol") | |
(ql:quickload "named-readtables")) | |
;;;; Define a package and a read table. |
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
<head> | |
<style> | |
.node { | |
stroke: #fff; | |
stroke-width: 1.5px; | |
} | |
.link { | |
fill: none; | |
stroke: #666; | |
stroke-width: 1.5px; |
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
(in-package #:cl-user) | |
(eval-when (:compile-toplevel :load-toplevel :execute) | |
(ql:quickload "cl-ppcre") | |
(ql:quickload "optima") | |
(ql:quickload "optima.ppcre") | |
(use-package '#:optima) | |
(use-package '#:optima.ppcre)) | |
(defun ensure-all-system-are-downloaded () |
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
(in-package #:cl-user) | |
;; Must do ... | |
;; (setf slime-enable-evaluate-in-emacs t) | |
;; ... in emacs first. And, dot must be installed. | |
(defun graph-quicklisp-system (ql-system-designation) | |
"Display graph of system requirements." | |
(let ((dot-file "/tmp/ql-system.dot") | |
(png-file "/tmp/ql-system.png")) |
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
211.110.140.155 - - [19/Nov/2013:17:30:37 -0800] "GET /wp-login.php HTTP/1.1" 200 3163 "http://enthusiasm.cozy.org/wp-login.php" "Mozilla/4.0 (compatible; MSIE 9.0; Windows NT 6.1; 125LA; .NET CLR 2.0.50727; .NET CLR 3.0.04506.648; .NET CLR 3.5.21022)" | |
211.110.140.155 - - [19/Nov/2013:17:30:38 -0800] "GET /wp-login.php HTTP/1.1" 200 3163 "-" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)" | |
211.110.140.155 - - [19/Nov/2013:17:30:39 -0800] "GET /wp-login.php HTTP/1.1" 200 3163 "-" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)" | |
211.110.140.155 - - [19/Nov/2013:17:30:40 -0800] "GET /?author=1 HTTP/1.1" 301 353 "http://enthusiasm.cozy.org/?author=1" "Mozilla/4.0 (compatible; MSIE 9.0; Windows NT 6.1; 125LA; .NET CLR 2.0.50727; .NET CLR 3.0.04506.648; .NET CLR 3.5.21022)" | |
211.110.140.155 - - [19/Nov/2013:17:30:41 -0800] "GET /?author=1 HTTP/1.1" 301 353 "-" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)" | |
211.110.140.155 - - [19/Nov/2013:17:30:43 -0800] "GET /archives/author/admin HTTP/1.1" 200 4 |
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
(in-package #:cl-user) | |
;;; run each form in here one at a time by hand. | |
(ql:quickload '("cl-json" "drakma")) | |
(defparameter *all* ;; This takes quite a while. | |
(cl-json:decode-json-from-source | |
(drakma:http-request "https://registry.npmjs.org/-/all" :want-stream t))) |
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 *variable-memory* (make-hash-table :test #'equal)) | |
(fare-memoization:define-memo-function (intern-variable :table *variable-memory*) (name variable-specs) | |
(flet ((field? (n) | |
(cdr (assoc n variable-specs)))) | |
(make-instance 'variable | |
:name (json:lisp-to-camel-case (symbol-name name)) | |
:concept? (field? :concept) | |
:label (field? :label)))) |
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 google-query-history nil) | |
(defun google (query) | |
"Search google in the regular web browser, prefix arg for luck." | |
;; Mac only, due to the use of the unix open command. | |
(interactive | |
(list | |
(read-string "Query: " | |
(if (use-region-p) | |
(buffer-substring (region-beginning) (region-end)) |
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
[[ $# -gt 0 ]] || error 'Missing Argument(s)' | |
case $1 in | |
-h) check_args -h ; do_help ;; | |
--help) check_args --help ; do_help ;; | |
help) check_args help ; do_help ;; | |
add-key) check_args add-key url ; do_add_key $2 ;; | |
list-keys) check_args list-keys ; do_list_keys ;; | |
sign) check_args sign key_id file file ; do_sign $2 $3 $4 ;; | |
get) check_args get url ; do_get $2 ;; | |
*) check_args url ; do_get $1 ;; |
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
#!/usr/bin/python | |
# Doesnt work ... the can_verify result is probably the hint why not. | |
# based loosely on http://blog.oddbit.com/2011/05/09/signing-data-with-ssh-agent/ | |
# Script to generate a cryptographic signature over a bit of data | |
# The signing is done by the current ssh-agent, using the first key stored | |
# in that agent. Usually that is the current user. |