Skip to content

Commit 3b21e51

Browse files
authored
Merge pull request #158 from bkmgit/doap4
Use doap to generate list of supported XEPs
2 parents 4e0f2ff + 3cd439d commit 3b21e51

12 files changed

Lines changed: 718 additions & 181 deletions

File tree

.github/workflows/deploy.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,14 @@ jobs:
1212
image: opensuse/tumbleweed:latest
1313

1414
steps:
15-
- uses: actions/checkout@v6
1615
- name: install dependencies
1716
run: |
1817
zypper refresh
1918
zypper --non-interactive update
20-
zypper --non-interactive install git lowdown make sblg nodejs npm
19+
zypper --non-interactive install git libxslt lowdown make sblg nodejs npm
20+
- uses: actions/checkout@v6
21+
with:
22+
submodules: recursive
2123
- name: build css
2224
run: |
2325
npm install

.gitmodules

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
[submodule "blog_source"]
22
path = blog_source
33
url = https://github.com/profanity-im/blog
4+
[submodule "pagesource/doap"]
5+
path = pagesource/doap
6+
url = https://github.com/profanity-im/profanity.git

Makefile

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
SBLG = sblg
2+
XSLTPROC = xsltproc
23
PREFIX = $(PWD)/site
34
BLOG_SRC_TOP_DIR = blogsource/content
45
BLOG_POST_SRC_DIR = $(BLOG_SRC_TOP_DIR)/post
@@ -12,6 +13,7 @@ CONTRIBUTORS = $(wildcard $(CONTRIBUTORS_SRC_DIR)/*.md)
1213
PAGES_SRC_DIR = pagesource
1314
PAGES_SRC = $(wildcard $(PAGES_SRC_DIR)/*.xml)
1415
PAGES = $(subst $(PAGES_SRC_DIR)/,,$(PAGES_SRC:.xml=.html))
16+
PAGES_SRC += "xeps.xml"
1517
REDIRECTS_DIR = pageredirects
1618
REDIRECTS_SRC = $(wildcard $(REDIRECTS_DIR)/*.html)
1719
REDIRECTS = $(subst $(REDIRECTS_DIR)/,,$(REDIRECTS_SRC))
@@ -47,11 +49,20 @@ index.html: landing-template.xml index.xml profanity_version.txt
4749
$(SBLG) -o $@ -t landing-template.xml -c index.gen.xml
4850
rm -f index.gen.xml
4951

50-
$(PAGES): manual-template.xml
52+
$(PAGES): manual-template.xml xeplist
5153
cp --preserve=mode,ownership,timestamps $(addprefix $(PAGES_SRC_DIR)/,$(@:.html=.xml)) .
5254
$(SBLG) -o $@ -t manual-template.xml -c $(@:.html=.xml)
5355
rm -f $(PAGES:.html=.xml)
5456

57+
xeplist: $(PAGES_SRC_DIR)/doap-stylesheet/style.xsl $(PAGES_SRC_DIR)/doap/profanity.doap \
58+
$(PAGES_SRC_DIR)/xeplist/xeplist.xml
59+
cp --preserve=mode,ownership,timestamps $(PAGES_SRC_DIR)/xeplist/xeplist.xml \
60+
$(PAGES_SRC_DIR)/doap-stylesheet/
61+
$(XSLTPROC) $(PAGES_SRC_DIR)/doap-stylesheet/style.xsl \
62+
$(PAGES_SRC_DIR)/doap/profanity.doap \
63+
> $(PAGES_SRC_DIR)/xeps.xml
64+
rm $(PAGES_SRC_DIR)/doap-stylesheet/xeplist.xml
65+
5566
themegallery.html: gallery-template.xml
5667
$(SBLG) -o $@ -t gallery-template.xml -c themegallery.xml
5768

@@ -77,6 +88,6 @@ $(REDIRECTS): $(REDIRECTS_SRC)
7788
clean:
7889
$(MAKE) -C $(BLOG_POST_SRC_DIR) clean
7990
$(MAKE) -C $(CONTRIBUTORS_SRC_DIR) clean
80-
rm -f index.html $(PAGES) themegallery.html $(REDIRECTS)
91+
rm -f index.html $(PAGES) themegallery.html $(REDIRECTS) $(PAGES_SRC_DIR)/xeps.xml
8192
rm -r $(BLOG_POSTS_XML) $(BLOG_POSTS_OUT) $(BLOG_POST_OUT_TOP_DIR)
8293
rm -r $(CONTRIBUTORS_XML) $(CONTRIBUTORS_OUT) $(CONTRIBUTORS_OUT_DIR)

README.md

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ The website is generated from XML and Markdown sources using [sblg](https://kris
1717
| **Style** | `css/*.css` | CSS |
1818

1919
### Page Sources
20-
The source files for the landing page (`index.xml`) and other top level pages in `pagesource/` are XML fragments. They contain the HTML content for the body, which is then injected into the appropriate header and footer templates.
20+
The source files for the landing page (`index.xml`) and other top level pages in `pagesource/` are XML fragments. They contain the HTML content for the body, which is then injected into the appropriate header and footer templates. The list of supported XEPS is generated using a git submodule for https://github.com/profanity-im/profanity/blob/master/profanity.doap.
2121

2222
### Blog
2323
Blog posts and contributor profiles are written in Markdown.
@@ -35,7 +35,15 @@ Command references (`main_fragment.html`, `toc_fragment.html`) and apidocs are g
3535
### Build & Deploy
3636
GitHub Actions will automatically build and deploy the website to GitHub Pages on every push.
3737

38-
To build the site locally, run `make` in the top level directory. You will need `sblg` and `lowdown` installed on your system.
38+
To build the site locally, run
39+
```
40+
git clone https://github.com/profanity-im/profanity-im.github.io.git
41+
cd profanity-im.github.io
42+
git submodule update --init --recursive
43+
make
44+
```
45+
46+
You will need `sblg`, `lowdown` and `libxslt` installed on your system.
3947

4048
To preview the site locally, run `make install` which will create a directory `site`, open `site/index.html` in a web browser.
4149

pagesource/doap

Submodule doap added at 89fce43

0 commit comments

Comments
 (0)