Skip to content

Commit 0766cb8

Browse files
Merge pull request #3748 from raspberrypi/develop
Release updated Connect screenshots with new auto-cache-busting image pipeline
2 parents 2261f7a + 14b1572 commit 0766cb8

11 files changed

+16
-3
lines changed
-53.6 KB
Loading
-245 KB
Loading
-245 KB
Loading
-249 KB
Loading
-245 KB
Loading
-249 KB
Loading
-2.62 MB
Loading
5.59 KB
Loading

documentation/asciidoc/services/connect/use.adoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ image::images/screen-sharing-end.png[width="80%"]
103103

104104
To turn off screen sharing, click the Connect system tray icon and unselect **Allow screen sharing**. Your Raspberry Pi remains signed into Connect, but you won't be able to create a screen sharing session from the Connect dashboard.
105105

106-
image:images/screen-sharing-disabled-desktop.png[width="80%"]
106+
image::images/screen-sharing-disabled-desktop.png[width="80%"]
107107

108108
Alternatively, you can disable screen sharing with the following command:
109109

@@ -168,7 +168,7 @@ image::images/remote-shell-end.png[width="80%"]
168168

169169
To turn off remote shell access, click the Connect system tray icon and unselect **Allow remote shell**. Your Raspberry Pi remains signed into Connect, but you won't be able to create a remote shell session from the Connect dashboard.
170170

171-
image:images/remote-shell-disabled-desktop.png[width="80%"]
171+
image::images/remote-shell-disabled-desktop.png[width="80%"]
172172

173173
Alternatively, you can disable remote shell access with the following command:
174174

scripts/create_build_adoc.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ def check_no_markdown(filename):
2121
if re.search(r'(\[.+?\]\(.+?\))', asciidoc):
2222
raise Exception("{} contains a Markdown-style link (i.e. '[title](url)' rather than 'url[title]')".format(filename))
2323

24-
2524
if __name__ == "__main__":
2625
index_json = sys.argv[1]
2726
config_yaml = sys.argv[2]
@@ -72,6 +71,12 @@ def check_no_markdown(filename):
7271
m = re.match(r'^(include::)(.+)(\[\]\n?)$', line)
7372
if m:
7473
line = m.group(1) + os.path.join('{includedir}/{parentdir}', m.group(2)) + m.group(3)
74+
# find all image references, append md5 hash at end to bust the cache if we change the image
75+
m = re.match(r'^(image::)(.+)(\[(.+)]\n?)$', line)
76+
if m:
77+
directory = os.path.dirname(os.path.abspath(src_adoc))
78+
image_hash = hashlib.md5(open(os.path.join(directory, m.group(2)),'rb').read()).hexdigest()
79+
line = m.group(1) + m.group(2) + '?hash=' + image_hash + m.group(3) + "\n"
7580
new_contents += line
7681

7782
with open(build_adoc, 'w') as out_fh:

0 commit comments

Comments
 (0)