diff --git a/.gitignore b/.gitignore index d39d50c..0f9a418 100644 --- a/.gitignore +++ b/.gitignore @@ -55,3 +55,9 @@ hugo* # security-sensitive files *.gpg + +# vim temporary files +*.swp + +# hugo lock files +*.hugo_build.lock diff --git a/reference/themes/mongodb/layouts/partials/header.html b/reference/themes/mongodb/layouts/partials/header.html index 65fc394..71025f5 100644 --- a/reference/themes/mongodb/layouts/partials/header.html +++ b/reference/themes/mongodb/layouts/partials/header.html @@ -7,6 +7,9 @@ {{.Title}} {{- partial "assets/css.html" . -}} + + {{- partial "header/metaRedirect.html" . -}} + @@ -25,6 +28,3 @@
- {{ if ( and ( findRE ".*mongo-java-driver/4.3/.+" .URL ) ( not ( findRE ".*/apidocs/.*" .URL )) ( not ( findRE ".*/driver-scala/.*" .URL )) (not ( findRE ".*/driver-reactive/.*" .URL ))) }} - {{- partial "header/newSiteNotice.html" . -}} - {{ end }} diff --git a/reference/themes/mongodb/layouts/partials/header/metaRedirect.html b/reference/themes/mongodb/layouts/partials/header/metaRedirect.html new file mode 100644 index 0000000..9685f45 --- /dev/null +++ b/reference/themes/mongodb/layouts/partials/header/metaRedirect.html @@ -0,0 +1,12 @@ +{{ if ( and ( findRE ".*mongo-java-driver/4.4/.+" .URL ) ( not ( findRE ".*/apidocs/.*" .URL )) ( not ( findRE ".*/driver-scala/.*" .URL )) (not ( findRE ".*/driver-reactive/.*" .URL ))) }} + + + +{{ end }} + +{{ if ( and ( findRE ".*mongo-java-driver/4.3/.+" .URL ) ( not ( findRE ".*/apidocs/.*" .URL )) ( not ( findRE ".*/driver-scala/.*" .URL )) (not ( findRE ".*/driver-reactive/.*" .URL ))) }} + + + +{{ end }} +