Skip to content

Commit

Permalink
site: fix build errors
Browse files Browse the repository at this point in the history
  • Loading branch information
mcraveiro committed Jan 13, 2024
1 parent 386ae64 commit ca48713
Show file tree
Hide file tree
Showing 4 changed files with 61 additions and 17 deletions.
68 changes: 55 additions & 13 deletions .build-site.el
Original file line number Diff line number Diff line change
@@ -1,6 +1,37 @@
;; Set the package installation directory so that packages aren't stored in the
;; ~/.emacs.d/elpa path.
;;; .build-site.el --- Build progen site.
;;
;; Copyright (C) 2023 Marco Craveiro
;;
;; Author: Marco Craveiro <[email protected]>
;; Maintainer: Marco Craveiro <[email protected]>
;; URL: https://github.com/MASD-Project/progen/blob/main/.build-site.el
;;
;; This program is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;;
;; This program is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;;
;; You should have received a copy of the GNU General Public License
;; along with this program. If not, see <https://www.gnu.org/licenses/>.
;;
;;; Commentary:
;;
;; Builds the progen site under the build directory.
;;
;;; Code:
(require 'package)
(require 'org)
(require 'org-id)
(require 'ox-publish)
(require 'org-element)

(setq org-id-locations-file (expand-file-name "./.org-id-locations-file"))
(org-id-update-id-locations (directory-files-recursively "." "\\.org$"))
(setq package-user-dir (expand-file-name "./.packages"))
(setq package-archives '(("melpa" . "https://melpa.org/packages/")
("elpa" . "https://elpa.gnu.org/packages/")))
Expand All @@ -24,19 +55,30 @@

;; Define the publishing project
(setq org-publish-project-alist
(list
(list "org-site:main"
:recursive t
:base-directory "./"
:publishing-function 'org-html-publish-to-html
:publishing-directory "./build/output/site"
:with-author nil ;; Don't include author name
:with-creator t ;; Include Emacs and Org versions in footer
:with-toc t ;; Include a table of contents
:section-numbers nil ;; Don't include section numbers
:time-stamp-file nil))) ;; Don't include time stamp in file
'(
("progen-site:pages"
:recursive t
:base-directory "./"
:publishing-function org-html-publish-to-html
:publishing-directory "./build/output/site"
:with-author nil ;; Don't include author name
:with-creator t ;; Include Emacs and Org versions in footer
:with-toc t ;; Include a table of contents
:section-numbers nil ;; Don't include section numbers
:time-stamp-file nil) ;; Don't include time stamp in file
("progen-site:images"
:base-directory "./assets/images"
:base-extension "png\\|jpg"
:publishing-directory "./build/output/site"
:publishing-function org-publish-attachment)
( "progen-site:main"
:components("progen-site:images" "progen-site:pages"))
))

;; Generate the site output
(org-publish-all t)

(message "Build complete!")

(provide '.build-site)
;;; .build-site.el ends here
1 change: 0 additions & 1 deletion .github/workflows/build-site.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ jobs:
- name: Build site
run: |
emacs -Q --script .build-site.el
cp -r assets/ build/output/site/
- name: Setup Pages
uses: actions/configure-pages@v3
- name: Upload artifact
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
build/output

# Emacs
.packages
.org-id-locations-file
6 changes: 3 additions & 3 deletions models/masd.org
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ is a working context with a set of associated concepts, body of knowledge,
tools, required skills, and possibilities." Mens and Van Gorp subsequently
\marginpar{Definition} updated the language and tightened the notion by
connecting it to metametamodels: "A technical space is determined by the
metametamodel that is used (M3-level)." cite:mens2006taxonomy (/cf,/ Section
[[#metamodelling-hierarchy]]) Examples of acrshortpl:ts include acrshort:mde itself,
acrshort:xml, Java and other such programming languages.
metametamodel that is used (M3-level)." cite:mens2006taxonomy Examples of
acrshortpl:ts include acrshort:mde itself, acrshort:xml, Java and other such
programming languages.

#+begin_src bibtex :tangle yes
@article{kurtev2002technological,
Expand Down

0 comments on commit ca48713

Please sign in to comment.