Skip to content

Commit f7ceee3

Browse files
authored
Update image instructions in README.md
1 parent c82c9d1 commit f7ceee3

File tree

1 file changed

+11
-9
lines changed

1 file changed

+11
-9
lines changed

README.md

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -62,31 +62,33 @@ hugo server &
6262
http://localhost:1313/ will reload seconds later so you can instantly see the changes!
6363

6464

65-
#### Seeing images on localhost
65+
#### Seeing historic images on localhost
6666

67-
At the moment (2025-03-05), historic images live in a large separate repo
68-
https://github.com/OBF/wp-content/ which is included as a git submodule.
69-
If you want to view images in the web pages on localhost:1313, you will need
67+
Historic images from when the website was on WordPress live in a large separate
68+
repo https://github.com/OBF/wp-content/ which is included as a git submodule.
69+
If you want to view images in the web pages on `localhost:1313`, you will need
7070
to also initialise this repository, which is currently setup using the
7171
`git submodule` workflow. **By default the `wp-content` submodule is not cloned**
7272

7373
To load it you can run:
7474

75-
* `cd OBF.github.io/`
76-
* `git submodule init`
77-
* `git submodule update`
75+
```
76+
cd OBF.github.io/
77+
git submodule init
78+
git submodule update
79+
```
7880

7981
Getting the files can take a while (the `wp-content` repo is ~500 MB).
8082

8183
This may change.
8284

8385
#### Adding new images
8486

85-
For new images, you can place these into the `static/img` folder of this repository, ideally in a subfolder based on the four digit year.
87+
For new images, you can place these into the `static/img/yyyy/` folder of this repository, where `yyyy` means the four digit year as a subfolder.
8688

8789
When compiling the website during the build, Hugo will move everything in `static/` into the website root, i.e. to `open-bio.org/`. This means that when linking images you do not have to include the `static/` as part of the media/image link.
8890

89-
As an example: A file that resides in `static/img/test-image.jpg` should be linked in the markdown files like this: `![an image](/img/test-image.jpg)`
91+
As an example: A file that resides in `static/img/2025/test-image.jpg` should be linked in the markdown files like this: `![an image](/img/2025/test-image.jpg)`
9092

9193
It is also good practice to name media files with the date you add them/the date of the page/post you want to add them to, e.g. `static/img/2025/2025-03-04-blogpost-image.jpg` (using `yyyy-mm-dd` as the start of the filename).
9294

0 commit comments

Comments
 (0)