Skip to content

Commit 5932438

Browse files
committedJan 21, 2020
Remove unwanted tracking from distributed HTML man pages
This was supposed to end up in the published site only
1 parent e66ef8d commit 5932438

File tree

2 files changed

+5
-8
lines changed

2 files changed

+5
-8
lines changed
 

‎man-template.html

-8
Original file line numberDiff line numberDiff line change
@@ -93,11 +93,3 @@ <h1>{{.Title}}</h1>
9393
<li class="tr"></li>
9494
</ol>
9595
</footer>
96-
97-
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-3769691-115"></script>
98-
<script>
99-
window.dataLayer = window.dataLayer || [];
100-
function gtag(){dataLayer.push(arguments);}
101-
gtag('js', new Date());
102-
gtag('config', 'UA-3769691-115');
103-
</script>

‎script/publish-release

+5
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@ publish_documentation() {
1313

1414
git rm hub*.html >/dev/null
1515
cp ../share/doc/*/*.html .
16+
17+
local tracking="$(sed -n '/googletagmanager/,/^<\/script/p' index.html)"
18+
local man_page
19+
for man_page in hub*.html; do cat <<<"$tracking" >>"$man_page"; done
20+
1621
git add hub*.html
1722
GIT_COMMITTER_NAME='GitHub Actions' GIT_COMMITTER_EMAIL='mislav+actions@github.com' \
1823
GIT_AUTHOR_NAME='Mislav Marohnić' GIT_AUTHOR_EMAIL='mislav@github.com' \

0 commit comments

Comments
 (0)
Please sign in to comment.