Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 0fedbc5a60 | |||
| b3fd193c40 | |||
| 80c3617562 |
@@ -1,4 +1,5 @@
|
|||||||
dist
|
dist
|
||||||
|
dist_gemini
|
||||||
build
|
build
|
||||||
.idea
|
.idea
|
||||||
|
|
||||||
|
|||||||
@@ -5,13 +5,27 @@ RES_DIR = res
|
|||||||
PAGES_DIR = $(SRC_DIR)/pages
|
PAGES_DIR = $(SRC_DIR)/pages
|
||||||
BLOG_DIR = $(SRC_DIR)/blog
|
BLOG_DIR = $(SRC_DIR)/blog
|
||||||
DIST_DIR = dist
|
DIST_DIR = dist
|
||||||
|
GEMINI_DIST_DIR = dist_gemini
|
||||||
BUILD_DIR = build
|
BUILD_DIR = build
|
||||||
|
|
||||||
PAGES = $(notdir $(wildcard $(PAGES_DIR)/*.html))
|
PAGES = $(notdir $(wildcard $(PAGES_DIR)/*.html))
|
||||||
BLOG_PAGES = $(wildcard $(BLOG_DIR)/*.md)
|
BLOG_PAGES = $(wildcard $(BLOG_DIR)/*.md)
|
||||||
TARGETS = $(addprefix $(DIST_DIR)/,$(PAGES))
|
TARGETS = $(addprefix $(DIST_DIR)/,$(PAGES))
|
||||||
|
GEMINI_TARGETS = $(addprefix $(GEMINI_DIST_DIR)/,$(patsubst %.html, %.gem, $(filter-out blog.html, $(PAGES))))
|
||||||
|
|
||||||
all: $(PAGES_DIR)/blog.html $(TARGETS) favicon
|
all: $(PAGES_DIR)/blog.html $(TARGETS) gemini
|
||||||
|
|
||||||
|
mkdir_gemini:
|
||||||
|
mkdir -p $(GEMINI_DIST_DIR)
|
||||||
|
mkdir -p $(GEMINI_DIST_DIR)/blog
|
||||||
|
|
||||||
|
$(GEMINI_DIST_DIR)/%.gem: $(DIST_DIR)/%.html | mkdir_gemini
|
||||||
|
pandoc -f html -t markdown $(DIST_DIR)/$*.html | md2gemini > $(GEMINI_DIST_DIR)/$*.gem
|
||||||
|
|
||||||
|
gemini_blog: | mkdir_gemini
|
||||||
|
find $(BLOG_DIR) -iname "*.md" -exec bash -c 'md2gemini < {} > $(GEMINI_DIST_DIR)/blog/`basename -s .md {}`.gem' \;
|
||||||
|
|
||||||
|
gemini: $(TARGETS) $(GEMINI_TARGETS) gemini_blog
|
||||||
|
|
||||||
watch:
|
watch:
|
||||||
find ./$(SRC_DIR) -iname '*.html' -o -name "*.css" | entr -d make -f ./Makefile ;
|
find ./$(SRC_DIR) -iname '*.html' -o -name "*.css" | entr -d make -f ./Makefile ;
|
||||||
@@ -39,3 +53,4 @@ clean:
|
|||||||
rm -rf $(DIST_DIR)
|
rm -rf $(DIST_DIR)
|
||||||
rm -rf $(BUILD_DIR)
|
rm -rf $(BUILD_DIR)
|
||||||
rm -rf $(PAGES_DIR)/blog.html
|
rm -rf $(PAGES_DIR)/blog.html
|
||||||
|
rm -rf $(GEMINI_DIST_DIR)
|
||||||
|
|||||||
+1
-1
@@ -3,7 +3,7 @@
|
|||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<title>rhetenors_homepage.index()</title>
|
<title>rhetenor's homepage</title>
|
||||||
<link rel="stylesheet" href="styles/style.css">
|
<link rel="stylesheet" href="styles/style.css">
|
||||||
<link rel="stylesheet" href="styles/main.css">
|
<link rel="stylesheet" href="styles/main.css">
|
||||||
<link rel="stylesheet" href="styles/aside.css">
|
<link rel="stylesheet" href="styles/aside.css">
|
||||||
|
|||||||
Reference in New Issue
Block a user