Skip to content

Commit c94c28a

Browse files
committed
try combined build
1 parent 41d190f commit c94c28a

File tree

5 files changed

+69
-64
lines changed

5 files changed

+69
-64
lines changed

.github/workflows/mkdocs_pdf.yml

Lines changed: 9 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33

44
name: test MD help to .pdf
55

6-
#on: [workflow_dispatch]
7-
on: [push, workflow_dispatch]
6+
on: [workflow_dispatch]
7+
#on: [push, workflow_dispatch]
88

99
permissions:
1010
contents: write
@@ -16,23 +16,13 @@ jobs:
1616
runs-on: ubuntu-latest
1717
steps:
1818

19-
20-
# - name: Set up Node.js
21-
# uses: actions/setup-node@v4
22-
23-
# - name: Install RelaxedJS globally
24-
# run: npm install -g relaxedjs
25-
# #- name: Install RelaxedJS locally
26-
# # run: npm install relaxedjs
27-
28-
# - name: find relaxedjs
29-
# run: |
30-
# which relaxed
31-
32-
# - name: test installed chrome
33-
# run: |
34-
# which chrome
35-
# chrome --version
19+
- name: Python setup
20+
uses: actions/setup-python@v3
21+
# - name: Sphinx setup
22+
# run: |
23+
# pip install sphinx sphinx_readable_theme
24+
# - name: pandoc setup
25+
# uses: pandoc/actions/setup@v1
3626

3727
- name: install debian chrome
3828
run: |
@@ -45,30 +35,6 @@ jobs:
4535
# which google-chrome-stable
4636
# google-chrome-stable --version
4737
# /usr/bin/google-chrome-stable --headless --disable-gpu --dump-dom https://google.com
48-
49-
# - name: Setup chromium
50-
# uses: browser-actions/setup-chrome@v1
51-
# id: setup-chrome
52-
# with:
53-
# install-dependencies: true
54-
# install-chromedriver: true
55-
# - run: |
56-
# echo ${{ steps.setup-chrome.outputs.chrome-path }} --version
57-
# ${{ steps.setup-chrome.outputs.chrome-path }} --version
58-
# - name: test installed chrome
59-
# run: |
60-
# ${{ steps.setup-chrome.outputs.chrome-path }} --no-sandbox --headless --disable-gpu --dump-dom https://google.com
61-
# - name: test system chromium
62-
# run: |
63-
# /usr/bin/chromium-browser --no-sandbox --headless --disable-gpu --dump-dom https://google.com
64-
65-
- name: Python setup
66-
uses: actions/setup-python@v3
67-
# - name: Sphinx setup
68-
# run: |
69-
# pip install sphinx sphinx_readable_theme
70-
# - name: pandoc setup
71-
# uses: pandoc/actions/setup@v1
7238
- name: mkdocs setup
7339
run: |
7440
pip install mkdocs mkdocs-material python-markdown-math mkdocs-static-i18n

.github/workflows/test_builddocsite.yml

Lines changed: 31 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,19 @@
11
# create a documentation web site for GSAS-II from four sources
22
# * HTML tutorials are simply copied
33
# * markdown tutorials (in ./MDtutorials) are formatted with pandoc and are copied over
4-
# * HTML help files are copied over from the GSAS-II sources
54
# * sphinx is used to generate HTML from files in ./webdocs
65

76
# Also the tutorials.html file and the */data/index.html files are
87
# created by running scripts/makeGitTutorial
98

109
# this is a development version that creates draft help pages from the MDhelp directory
10+
For now
11+
# * HTML help files are copied over from the GSAS-II sources
1112

12-
name: test MD help w/build GSAS-II web site
13+
name: build GSAS-II web site w/test MD Help
1314

14-
on: [workflow_dispatch]
15-
#on: [push, workflow_dispatch]
15+
#on: [workflow_dispatch]
16+
on: [push, workflow_dispatch]
1617

1718
permissions:
1819
contents: write
@@ -29,21 +30,45 @@ jobs:
2930
- name: Sphinx setup
3031
run: |
3132
pip install sphinx sphinx_readable_theme
32-
#pip install mkdocs-to-pdf
3333
- name: pandoc setup
3434
uses: pandoc/actions/setup@v1
35+
36+
# MD help stuff
37+
- name: install debian chrome
38+
run: |
39+
set -ex
40+
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
41+
sudo apt install ./google-chrome-stable_current_amd64.deb
42+
43+
# - name: test newly-installed chrome
44+
# run: |
45+
# which google-chrome-stable
46+
# google-chrome-stable --version
47+
# /usr/bin/google-chrome-stable --headless --disable-gpu --dump-dom https://google.com
3548
- name: mkdocs setup
3649
run: |
3750
pip install mkdocs mkdocs-material python-markdown-math mkdocs-static-i18n
51+
pip install mkdocs-to-pdf pymdown-extensions
3852
3953
- name: Checkout
4054
uses: actions/checkout@v4
4155

56+
# MD help stuff
4257
- name: convert MDhelp
4358
run: |
4459
cd MDhelp
4560
mkdocs build
4661
cp -vr site ../help_test
62+
ENABLE_PDF_EXPORT=1 mkdocs build
63+
mv site/GSASII-help.pdf ../docs/
64+
cp -vr site ../help_test
65+
66+
# - name: Upload help artifact # creates zip file with website contents
67+
# uses: actions/upload-pages-artifact@v3
68+
# with:
69+
# path: MDhelp/site
70+
# name: MDhelp
71+
# retention-days: 1
4772

4873
- name: Get tutorials index from source code
4974
run: |
@@ -89,6 +114,7 @@ jobs:
89114
sphinx-build webdocs . # place output into root dir
90115
cp webdocs/_static/fix.css _static/fix.css # should be done by sphinx
91116
117+
# to be replaced by MD help stuff
92118
# get the help pages from the GSAS-II sources into the web site
93119
- name: Get GSAS-II
94120
run: |

MDhelp/docs/index.md

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,18 +10,20 @@ right corner of the data window. Access to specific help information
1010
is also offered on the graphics
1111
window and in other locations of the program.
1212

13+
<a name="Index"></a>
1314
An index on the topics covered in these help pages is given below.
1415

15-
<a name="Index"></a>
1616
1. [Tutorials](./preface.md)
17-
2. [GSAS-II GUI Organization](./applicationwindow.md)
17+
2. [GSAS-II GUI Organization](./applicationwindow.md)
1818
1. [Data Tree](./applicationwindow.md#Data_tree)
19-
1. [Data Window](./applicationwindow.md#Data_frame)
20-
1. [Graphics Window](./applicationwindow.md#Plots)
21-
1. [Console Window](./applicationwindow.md#Console)
19+
2. [Data Window](./applicationwindow.md#Data_frame)
20+
3. [Graphics Window](./applicationwindow.md#Plots)
21+
4. [Console Window](./applicationwindow.md#Console)
2222
3. [Main menu contents](./mainmenu.md)
2323
4. Data tree entries and their use ([overview](./datatree.md))
24-
1. [Universal data tree](./commontreeitems.md) items
24+
1. [Universal data tree](./commontreeitems.md) items
25+
0. [Sequential results](./sequential.md)
26+
0. [Cluster Analysis](./cluster.md)
2527
2. [Phase Data Tree items (overview)](./phaseoverview.md)
2628
* [General Phase tab](./phasegeneral.md)
2729
* [Data Phase tab](./phasedata.md)
@@ -54,7 +56,6 @@ An index on the topics covered in these help pages is given below.
5456
* Reflection List
5557
6. [Pair Distribution Functions (PDF)](./pairdistribution.md) Data Tree entries
5658
8. [Small Angle Scattering (SASD)](./smallanglescattering.md) Data Tree entries
57-
9. [Reflectometry (REFD)](./reflectometry.md) Data Tree entries
58-
0. [Sequential results](./sequential.md)
59-
0. [Cluster Analysis](./cluster.md)
59+
9. [Reflectometry (REFD)](./reflectometry.md) Data Tree entries
60+
9. [Powder Peaks (PKS)](./peaks.md) Data Tree entries
6061
5. [Others](./others.md): Macintosh notes, Configuration options and Programmers' documentation

MDhelp/mkdocs.yml

Lines changed: 19 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ nav:
88
- Data tree items:
99
- Data tree overview: datatree.md
1010
- Universal items: commontreeitems.md
11+
- Sequential results: sequential.md
12+
- Cluster Analysis: cluster.md
1113
- Phases:
1214
- Phase overview: phaseoverview.md
1315
- General tab: phasegeneral.md
@@ -42,8 +44,7 @@ nav:
4244
- PDF: pairdistribution.md
4345
- Small Angle (SASD): smallanglescattering.md
4446
- Reflectometry (REFD): reflectometry.md
45-
- Sequential results: sequential.md
46-
- Cluster Analysis: cluster.md
47+
- Powder Peaks (PKS): peaks.md
4748

4849
# - Powder peaks (PKS): powderpeak.md
4950

@@ -57,6 +58,15 @@ theme:
5758
logo: images/gsas2.png
5859

5960
plugins:
61+
- to-pdf:
62+
author: Brian H. Toby and Robert B. Von Dreele
63+
enabled_if_env: ENABLE_PDF_EXPORT
64+
cover_title: GSAS-II Help information
65+
cover_subtitle: A compilation of HTML pages into PDF
66+
copyright: From https://advancedphotonsource.github.io/GSAS-II-tutorials/help/
67+
output_path: GSASII-help.pdf
68+
render_js: true
69+
headless_chrome_path: /usr/bin/google-chrome-stable
6070
- i18n:
6171
docs_structure: suffix
6272
languages:
@@ -71,11 +81,14 @@ plugins:
7181
markdown_extensions:
7282
- def_list
7383
- admonition
74-
- mdx_math
84+
# - mdx_math
85+
- pymdownx.arithmatex:
86+
generic: true
7587

76-
extra_javascript:
77-
- https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML
78-
# - https://unpkg.com/mathjax@3/es5/tex-mml-chtml.js # MathJax library from CDN
88+
extra_javascript:
89+
- javascripts/mathjax.js
90+
- https://unpkg.com/mathjax@3/es5/tex-mml-chtml.js
91+
# - https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML
7992

8093
#local build settings from https://www.mkdocs.org/user-guide/deploying-your-docs/#local-files
8194

MDhelp/mkdocs.yml_pdf

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,6 @@ extra_javascript:
9999
# - https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML
100100
# - https://unpkg.com/mathjax@3/es5/tex-mml-chtml.js # MathJax library from CDN
101101

102-
103102
#local build settings from https://www.mkdocs.org/user-guide/deploying-your-docs/#local-files
104103

105104
site_url: ""

0 commit comments

Comments
 (0)