Fixed and finished the search function
This commit is contained in:
27
Makefile
27
Makefile
@@ -1,15 +1,28 @@
|
||||
.PHONY: all clean norm help
|
||||
|
||||
# Default target: full build with search index
|
||||
all:
|
||||
@echo "Building project (full rebuild with search index)..."
|
||||
emacs -Q --script build-site.el
|
||||
python search-index-json.py
|
||||
VENV := .venv
|
||||
PY := $(VENV)/bin/python
|
||||
PIP := $(VENV)/bin/pip
|
||||
|
||||
all: build search
|
||||
|
||||
build:
|
||||
@echo "Building project..."
|
||||
emacs -Q --script build-site.el
|
||||
|
||||
search: $(VENV)
|
||||
@echo "Generating search index"
|
||||
$(PY) search-index-json.py
|
||||
|
||||
$(VENV):
|
||||
@echo "Generating virtual environment"
|
||||
python3 -m venv $(VENV)
|
||||
$(PIP) install -r requirements.txt
|
||||
|
||||
# Clean output directory
|
||||
clean:
|
||||
@echo "Cleaning output directory..."
|
||||
rm -rf output/
|
||||
rm -rf $(VENV)
|
||||
|
||||
norm:
|
||||
@echo "sorting out the backups..."
|
||||
@@ -19,6 +32,8 @@ norm:
|
||||
help:
|
||||
@echo "Available targets:"
|
||||
@echo " make - Full rebuild"
|
||||
@echo " make build - Rebuild the output directory"
|
||||
@echo " make clean - Remove output directory"
|
||||
@echo " make norm - Move all files that end with ~ to the backup folder"
|
||||
@echo " make search - creates the search index"
|
||||
@echo " make help - Show this help message"
|
||||
|
||||
Reference in New Issue
Block a user