Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
"name": "Common Lisp (SBCL)",
"image": "mcr.microsoft.com/devcontainers/base:ubuntu",
"features": {
"ghcr.io/devcontainers/features/common-utils:2": {
"installZsh": true,
"configureZshAsDefaultShell": true
}
},
"onCreateCommand": "sudo apt-get update && sudo apt-get install -y sbcl curl",
"postCreateCommand": ".devcontainer/setup.sh",
"customizations": {
"vscode": {
"extensions": [
"rheller.alive"
],
"settings": {
"alive.lsp.startCommand": ["sbcl", "--dynamic-space-size", "2048"],
"editor.formatOnSave": false,
"files.associations": {
"*.lisp": "lisp",
"*.asd": "lisp"
}
}
}
}
}
31 changes: 31 additions & 0 deletions .devcontainer/setup.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
#!/bin/bash
# Post-creation setup script for GitHub Codespaces
# Installs Quicklisp and required Common Lisp libraries

set -e

QUICKLISP_DIR="$HOME/quicklisp"

# Install Quicklisp if not already present
if [ ! -d "$QUICKLISP_DIR" ]; then
echo "Installing Quicklisp..."
tmpdir=$(mktemp -d)
curl -o "$tmpdir/quicklisp.lisp" https://beta.quicklisp.org/quicklisp.lisp
sbcl --load "$tmpdir/quicklisp.lisp" \
--eval '(quicklisp-quickstart:install)' \
--eval '(quit)'
rm -rf "$tmpdir"
echo "Quicklisp installed."
else
echo "Quicklisp already installed, skipping."
fi

# Load Quicklisp and install required libraries
# These match the ql:quickload calls in the .lisp source files.
# Update this list if new libraries are added to the project.
echo "Installing required Common Lisp libraries..."
sbcl --load "$QUICKLISP_DIR/setup.lisp" \
--eval "(ql:quickload '(:with-user-abort :adopt :str :parse-float :cl-charms :fuzzy-match :cl-csv :cl-ppcre) :silent t)" \
--eval '(quit)'

echo "Setup complete. SBCL and Common Lisp libraries are ready."
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Build artifacts from lisp/Makefile
lisp/bin/
lisp/man/