diff --git a/.github/workflows/deployment.yaml b/.github/workflows/deployment.yaml
new file mode 100644
index 0000000..7a7de8b
--- /dev/null
+++ b/.github/workflows/deployment.yaml
@@ -0,0 +1,55 @@
+name: Deploy to Pages
+
+on:
+ push:
+ branches: ["master"]
+
+ # Allows you to run this workflow manually from the Actions tab
+ workflow_dispatch:
+
+# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
+permissions:
+ contents: read
+ pages: write
+ id-token: write
+
+# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
+# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
+concurrency:
+ group: "pages"
+ cancel-in-progress: false
+
+jobs:
+ build:
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout files
+ uses: actions/checkout@v4
+ - name: Build static assets
+ shell: bash
+ run: make
+ - name: Upload static assets
+ uses: actions/upload-artifact@v4
+ with:
+ name: static_assets
+ path: ./static
+ deploy:
+ needs: build
+ environment:
+ name: github-pages
+ url: ${{ steps.deployment.outputs.page_url }}
+ runs-on: ubuntu-latest
+ steps:
+ - name: Download static_assets
+ uses: actions/download-artifact@v4
+ with:
+ name: static_assets
+ - name: Setup Pages
+ uses: actions/configure-pages@v5
+ - name: Upload artifact
+ uses: actions/upload-pages-artifact@v3
+ with:
+ path: ./
+ - name: Deploy to GitHub Pages
+ id: deployment
+ uses: actions/deploy-pages@v4
diff --git a/.gitignore b/.gitignore
index fc1dad7..7afe969 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,4 +1,5 @@
*~
*#*#
*.pdf
-*.html
+
+static
diff --git a/.travis.yml b/.travis.yml
deleted file mode 100644
index a3ad7d0..0000000
--- a/.travis.yml
+++ /dev/null
@@ -1,15 +0,0 @@
-# ref: https://docs.travis-ci.com/user/deployment/pages/
-
-services:
- - docker
-
-script: make
-
-deploy:
- provider: pages
- skip-cleanup: true
- github-token: $GITHUB_TOKEN
- keep-history: true
- on:
- branch: develop
- target-branch: master
diff --git a/Makefile b/Makefile
index e07eef5..742971b 100644
--- a/Makefile
+++ b/Makefile
@@ -14,7 +14,7 @@ ATTENTION_PREFIX := "\033[1;36m[!]\033[0m "
.PHONY: clean shell
-all: $(HTML_FILES)
+all: $(HTML_FILES) copy
shell:
$(DOCKER_RUN) -i --entrypoint=/bin/zsh $(DOCKER_IMG)
@@ -24,8 +24,21 @@ shell:
@$(DOCKER_RUN) $(DOCKER_IMG) $< $(EMACS_FLAGS) -f org-html-export-to-html
@$(DOCKER_RUN) --entrypoint=/bin/chown $(DOCKER_IMG) $(USER) "$*.html"
+copy:
+ @mkdir -p static
+ @find . \
+ "(" -name "*.html" -o -name "*.css" -o -name "*.js" ")" \
+ -not -path "./static/*" \
+ -not -path "./.github/*" \
+ -exec cp {} static \;
+ @find . \
+ -name "*.html" \
+ -not -path "./static/*" \
+ -not -path "./.github/*" \
+ -exec mv {} static \;
+
server:
- python3 -m http.server 8000
+ python3 -m http.server 8000 --directory ./static
clean:
- rm -rf *.html
+ rm -rf ./static
diff --git a/org-theme/setup/long.setup b/org-theme/setup/long.setup
index 7989871..eb2180f 100644
--- a/org-theme/setup/long.setup
+++ b/org-theme/setup/long.setup
@@ -20,6 +20,6 @@
# I recommend you to generate your own css/js files by forking, cloning and customizing the file
# theme.json before building it.
#
-#+HTML_HEAD:
-#+HTML_HEAD:
-#+HTML_HEAD:
+#+HTML_HEAD:
+#+HTML_HEAD:
+#+HTML_HEAD:
diff --git a/org-theme/setup/short.setup b/org-theme/setup/short.setup
index df93c51..3353017 100644
--- a/org-theme/setup/short.setup
+++ b/org-theme/setup/short.setup
@@ -17,6 +17,6 @@
# theme.json before building it.
#
#
-#+HTML_HEAD:
-#+HTML_HEAD:
-#+HTML_HEAD:
+#+HTML_HEAD:
+#+HTML_HEAD:
+#+HTML_HEAD: