Skip to content

Commit 830126d

Browse files
committed
Cleanup and syncronize changes with private branch
1 parent be84b10 commit 830126d

File tree

6 files changed

+43
-36
lines changed

6 files changed

+43
-36
lines changed

.github/workflows/gh-pages.yml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,11 @@ on:
2828
schedule:
2929
- cron: "0 3 * * *"
3030

31+
env:
32+
# ----------------------------------------------------------------------------
33+
# Specify the deployment environment: staging or production
34+
hugoEnvironment: production
35+
3136
jobs:
3237
# ----------------------------------------------------------------------------
3338
# Use the Zotero REST API to get the current version of the Zotero Bibliography
@@ -102,7 +107,7 @@ jobs:
102107
- name: Setup Hugo
103108
uses: peaceiris/actions-hugo@v3
104109
with:
105-
hugo-version: '0.122.0'
110+
hugo-version: '0.127.0'
106111
extended: true
107112

108113
- name: Setup Node
@@ -115,7 +120,7 @@ jobs:
115120
- run: npm install --verbose
116121

117122
- name: Build
118-
run: hugo
123+
run: hugo -e $hugoEnvironment
119124

120125
- name: Deploy
121126
uses: peaceiris/actions-gh-pages@v4

README.md

Lines changed: 30 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -147,12 +147,12 @@ hugo version
147147
The response will be something along the lines of:
148148

149149
```bash
150-
hugo v0.111.3-5d4eb5154e1fed125ca8e9b5a0315c4180dab192+extended linux/amd64 BuildDate=2023-03-12T11:40:50Z VendorInfo=gohugoio
150+
hugo v0.126.1-3d40aba512931031921463dafc172c0d124437b8+extended linux/amd64 BuildDate=2024-05-15T10:42:34Z VendorInfo=gohugoio
151151
```
152152

153-
Be sure your version is at least `v0.101.0`. Older versions of `hugo` may fail to load correctly.
153+
Be sure your version is at least `v0.122.0`. Older versions of `hugo` may fail to load correctly.
154154

155-
Secondly, there is one data file that is required to successfully build and run the `Interlisp.org` website locally, `data/bibliography.json`.
155+
Secondly, there is one data file that is required to successfully build and run the `Interlisp.org` website locally, `static/data/bibliography.json`.
156156
The production version of the website uses a GitHub Action to retrieve this file.
157157
We can mimic that functionality by going to the `scripts` directory in your clone of the `Intelisp.github.io` repository.
158158
Once in the directory, run the following command:
@@ -162,68 +162,73 @@ Once in the directory, run the following command:
162162
```
163163

164164
This script will retrieve the bibliography from our Zotero library, format it appropriately and place the created file
165-
in the appropriate location, the `data` directory.
165+
in the appropriate location, the `static/data` directory.
166166

167167
This completes all the setup required for `Hugo`.
168168

169169
To run `Hugo` go to the root directory of your repository clone and run the following command:
170170

171171
```bash
172-
hugo server
172+
hugo server --logLevel debug -v --renderToMemory -e development
173173
```
174174

175175
`Hugo` will start and automatically download the Docsy theme and its dependencies as hugo modules. You should see output along the lines of:
176176

177177
```bash
178-
hugo: downloading modules …
179-
hugo: collected modules in 17781 ms
178+
Watching for changes in /home/wstumbo/development/stumbo.github.io/{archetypes,content,layouts,package.json,static}
179+
Watching for config changes in /home/wstumbo/development/stumbo.github.io/config/_default, /home/wstumbo/development/stumbo.github.io/config/development, /home/wstumbo/development/stumbo.github.io/go.mod
180180
Start building sites …
181-
hugo v0.111.3-5d4eb5154e1fed125ca8e9b5a0315c4180dab192+extended linux/amd64 BuildDate=2023-03-12T11:40:50Z VendorInfo=gohugoio
181+
hugo v0.126.1-3d40aba512931031921463dafc172c0d124437b8+extended linux/amd64 BuildDate=2024-05-15T10:42:34Z VendorInfo=gohugoio
182+
182183

183184
| EN
184185
-------------------+-----
185-
Pages | 61
186+
Pages | 52
186187
Paginator pages | 0
187-
Non-page files | 13
188-
Static files | 68
189-
Processed images | 46
190-
Aliases | 4
191-
Sitemaps | 1
188+
Non-page files | 46
189+
Static files | 97
190+
Processed images | 47
191+
Aliases | 66
192192
Cleaned | 0
193193

194-
Built in 1349 ms
195-
Watching for changes in /home/wstumbo/development/Interlisp.github.io/{archetypes,assets,content,data,layouts,package.json,static,themes}
196-
Watching for config changes in /home/wstumbo/development/Interlisp.github.io/config.toml, /home/wstumbo/development/Interlisp.github.io/go.mod
194+
Built in 3230 ms
197195
Environment: "development"
198196
Serving pages from memory
199197
Running in Fast Render Mode. For full rebuilds on change: hugo server --disableFastRender
200-
Web Server is available at http://localhost:1313/ (bind address 127.0.0.1)
198+
Web Server is available at //localhost:1313/ (bind address 127.0.0.1)
201199
Press Ctrl+C to stop
202200
```
203201
204202
`Hugo` is now running. You can go to [http://localhost:1313](http://localhost:1313) to review the locally running version of the website.
205203
For most changes you should be able to review the text and layout to validate the effects are as expected.
206204
205+
You can get additional debugging information by adding the following two options
206+
to your `hugo` command `--logLevel debug -v`.
207+
207208
Once you have validated your changes, create a pull request to merge your changes into the `main` branch.
208209
209210
## Layout of the `Interlisp.github.io` repository
210211
211212
The layout of the `Interlisp.github.io` repository follows the standard [`Hugo` directory structure](https://gohugo.io/getting-started/directory-structure/). Directories
212213
that have components specific to `Interlisp.github.io` are as follows:
213214
214-
- `.` - at the root, `config.toml` file provides the general site configuration information
215215
- `.github\workflows` - home to the github actions `gh-pages.yml` that specifies how to build and release the Interlisp home page
216216
- `assets` - customization of the `Docsy` theme for Interlisp.
217217
- `icons` - holds and `svg` version of `Interlisp-D' logo. This logo is used in the page header
218218
- `scss` - contains some custom `scss`
219219
- `_styles_project.scss` sets the size of the `svg` file in the header and disables the edit page functionality
220220
- `main.scss` - links in the `scss` updates
221+
- `config` - contains all the site specific configuration information
222+
- `_default` - configuration information shared across different supported environments [development, staging, production]
223+
- `development` - configuration information specific to the development environment
224+
- `production` - configuration information specific to the production environment
225+
- `staging` - configuration information specific to the staging environment
221226
- `content\en` - home of all the content for the web page. We currently only support the English language. `Hugo` supports multiple languages and we have not disabled that feature. However there are no plans at present to transcribe the web pages and documentation into another language.
222-
- `data` - holds `bibliography.json` used to create the [bibliography table](https://interlisp.org/bibliography/)
223227
- `layout`
224228
- `shortcodes` - a simple snippet inside a content file that Hugo will render using a predefined template
225229
- `bibTable.html` - a shortcode used to format the [bibliography table](https://interlisp.org/bibliography/)
226230
- `static` - the data in this folder is copied directly into the folder structure of the home page
231+
- `data` - holds `bibliography.json` used to create the [bibliography table](https://interlisp.org/bibliography/)
227232
- `documentation` - contains the pdf files referenced in the document section of the home page
228233
- `favicons` - contains `favicon.png` a small icon that browsers can use when referencing the website
229234
- `Resources` - contains the current `Interlisp-D` logo, used on the home page, and another instance of `favicon.png`
@@ -236,11 +241,12 @@ the `Interlisp.org` website, our GitHub sites used for continued development of
236241
Medley Interlisp, and the discussions groups associated with both the Medley project and
237242
Interlisp.
238243
239-
The search engine is identified in the `hugo.toml` file:
244+
The search engine is identified in the `config/params.yaml` file:
240245
241-
```toml
242-
# Google Custom Search Engine ID. Remove or comment out to disable search.
243-
gcs_engine_id = "33ef4cbe0703b4f3a"
246+
```yaml
247+
# Google custom seach engine configuration
248+
# gcs_engine_id: search engine
249+
gcs_engine_id: 33ef4cbe0703b4f3ax
244250
```
245251
246252
Search results are returned and presented using the page template, `search.md`.

config/_default/params.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -152,3 +152,6 @@ ui:
152152

153153
ul_show: 3
154154

155+
# Identify the custom css files
156+
custom_css:
157+
- "css/custom.css"

data/.gitkeep

Whitespace-only changes.

data/carousel.yaml

Lines changed: 0 additions & 9 deletions
This file was deleted.

layouts/partials/hooks/body-end.html

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
<!-- ><script type="text/javascript" src="/js/carousel.js"></script>
22
<link rel="stylesheet" href="/css/carousel.css"> -->
3-
<link rel="stylesheet" href="/css/custom.css">
3+
{{range .Site.Params.custom_css -}}
4+
<link rel="stylesheet" href="{{ . | absURL }}">
5+
{{- end}}

0 commit comments

Comments
 (0)