Improve SEO by pre-rendering all HTML pages

* Change all internal links to use URLs ending in `/`
* Add the prerender script which uses PhantomJS to pre-render the
  HTML for all possible pages in the system
* Change the build process to incorporate the pre-rendered files
* Update the sitemap script to generate the new URLs
This commit is contained in:
Andrew Miner
2015-03-06 22:31:39 -08:00
parent a9dc4e3a26
commit 6c7274c38c
2121 changed files with 195933 additions and 3118 deletions
+3 -3
View File
@@ -2,7 +2,7 @@
export AWS_CONFIG_FILE="$HOME/Documents/CraftingGuide/aws.config"
DIST="./dist"
ROOT="./dist"
SITE="crafting-guide.com"
TARGET=""
while [[ "$1" != "" ]]; do
@@ -19,9 +19,9 @@ if [[ "$TARGET" == "" ]]; then
fi
if [[ "$TARGET" == "new" ]]; then
find "$DIST" -name ".DS_Store" | xargs rm
find "$ROOT" -name ".DS_Store" | xargs rm
grunt clean dist
s3cmd sync -r --delete-removed --add-header="cache-control:max-age=1800" "$DIST/" "s3://new.$SITE/"
s3cmd sync -r --delete-removed --add-header="cache-control:max-age=1800" "$ROOT/" "s3://new.$SITE/"
grunt clean build
elif [[ "$TARGET" == "promote" ]]; then
aws s3 sync "s3://new.$SITE" "s3://$SITE" --delete