aboutsummaryrefslogtreecommitdiff
path: root/roles/webserver/files/www/memzero/pub/abi
diff options
context:
space:
mode:
Diffstat (limited to 'roles/webserver/files/www/memzero/pub/abi')
-rw-r--r--roles/webserver/files/www/memzero/pub/abi/sysv/sysv-gabi4-2013/.fetch.sh24
1 files changed, 24 insertions, 0 deletions
diff --git a/roles/webserver/files/www/memzero/pub/abi/sysv/sysv-gabi4-2013/.fetch.sh b/roles/webserver/files/www/memzero/pub/abi/sysv/sysv-gabi4-2013/.fetch.sh
new file mode 100644
index 0000000..0ff7818
--- /dev/null
+++ b/roles/webserver/files/www/memzero/pub/abi/sysv/sysv-gabi4-2013/.fetch.sh
@@ -0,0 +1,24 @@
+#!/bin/bash
+
+rec_fetch() {
+ echo fetching $1
+ curl --no-progress-meter https://www.sco.com/developers/gabi/latest/$1 -o $1
+
+ # Handle following link tags:
+ # <a href=ch4.reloc.html>
+ # <a href=ch5.dynamic.html#pointer_note>
+ # <a href="ch4.sheader.html#sh_flags">
+ # <a href=#tag_encodings>
+ # <a href="#sh_type">
+ for page in $(grep href $1 |\
+ sed 's/.*href="\{0,1\}\([a-zA-Z._0-9]*\)"\{0,1\}[#>].*/\1/g' |\
+ sort | uniq); do
+ if [[ -z $page || -f $page || ${page##*.} != html ]]; then
+ continue;
+ fi
+
+ rec_fetch $page
+ done
+}
+
+rec_fetch contents.html