-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
56 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
|
||
Pikey is a Javascript compiler using Parenscript. | ||
|
||
It's work in progress. To build it, you need SBCL and quicklisp. Then evaluate | ||
|
||
(asdf:operate :program-op :pikey) | ||
|
||
and look in your fasl cache for the executable. I haven't looked up how to put | ||
it in the current working directory yet. | ||
|
||
Your fasl cache is usually ~/.cache/common-lisp/<sbcl|ccl|whatver>/path/to/source/etc. | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
;;;; package.lisp | ||
|
||
(defpackage #:pikey | ||
(:use #:cl | ||
#:parenscript) | ||
(:export :main)) | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
;;;; pikey.asd | ||
|
||
(asdf:defsystem #:pikey | ||
:description "Describe pikey here" | ||
:author "Your Name <[email protected]>" | ||
:license "Specify license here" | ||
:serial t | ||
|
||
|
||
:depends-on (#:cl-fad | ||
#:apply-argv | ||
#:parenscript) | ||
|
||
:components ((:file "package") | ||
(:file "pikey")) | ||
|
||
:build-pathname "pikey" | ||
:entry-point "pikey:main") | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
|
||
(in-package #:pikey) | ||
|
||
(eval-when (:compile-toplevel :load-toplevel) | ||
(defpsmacro gebi (element-id) | ||
`((@ document get-Element-By-Id) ,element-id))) | ||
|
||
(defun main () | ||
(let* ((args (apply-argv:parse-argv (cdr sb-ext:*posix-argv*))) | ||
(in-file (getf args :i)) | ||
(out-file (getf args :o)) | ||
(load-file (getf args :l))) | ||
(when (probe-file load-file) | ||
(setf *load-verbose* t) | ||
(setf *load-print* t) | ||
(load load-file)) | ||
(with-open-file (f out-file :if-exists :supersede :direction :output) | ||
(write-string (ps:ps-compile-file in-file) f)))) |