Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Have build.sh read from a template file[D

  • Loading branch information...
commit e94b04eb57da37698135ab5c4b2709d70d3dc5a3 1 parent b635ce5
@OscarGodson authored
Showing with 18 additions and 19 deletions.
  1. +2 −19 build.sh
  2. +16 −0 template.html
View
21 build.sh
@@ -1,24 +1,7 @@
#!/bin/bash
-# Create the template
-read -d '' template <<- EOF
-<!DOCTYPE html>
-<html>
- <head>
- <title>HTML6 - The Spec That Brings Us Freedom</title>
- <meta name="description" content="HTML5 was a great leap forward for web developers, however there is a void that HTML5 has yet to fix and that void is truly semantic markup.">
- <link rel="stylesheet" type="text/css" href="css/style.css" />
- <script>var _gaq=_gaq||[];_gaq.push(["_setAccount","UA-4491651-7"]);_gaq.push(["_trackPageview"]);(function(){var a=document.createElement("script");a.type="text/javascript";a.async=true;a.src=("https:"==document.location.protocol?"https://ssl":"http://www")+".google-analytics.com/ga.js";var b=document.getElementsByTagName("script")[0];b.parentNode.insertBefore(a,b)})()</script>
- </head>
- <body>
- <a href="https://github.com/OscarGodson/HTML6"><img style="position: absolute; top: 0; right: 0; border: 0;" src="https://s3.amazonaws.com/github/ribbons/forkme_right_gray_6d6d6d.png" alt="Fork me on GitHub"></a>
- %s
- <script src="js/jquery-1.8.0.min.js"></script>
- <script src="js/prettify.js"></script>
- <script src="js/main.js"></script>
- </body>
-</html>
-EOF
+# Get the template
+template=`cat template.html`
# Save the file
printf "$template" "$(marked --gfm < README.md)" > index.html
View
16 template.html
@@ -0,0 +1,16 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <title>HTML6 - The Spec That Brings Us Freedom</title>
+ <meta name="description" content="HTML5 was a great leap forward for web developers, however there is a void that HTML5 has yet to fix and that void is truly semantic markup.">
+ <link rel="stylesheet" type="text/css" href="css/style.css" />
+ <script>var _gaq=_gaq||[];_gaq.push(["_setAccount","UA-4491651-7"]);_gaq.push(["_trackPageview"]);(function(){var a=document.createElement("script");a.type="text/javascript";a.async=true;a.src=("https:"==document.location.protocol?"https://ssl":"http://www")+".google-analytics.com/ga.js";var b=document.getElementsByTagName("script")[0];b.parentNode.insertBefore(a,b)})()</script>
+ </head>
+ <body>
+ <a href="https://github.com/OscarGodson/HTML6"><img style="position: absolute; top: 0; right: 0; border: 0;" src="https://s3.amazonaws.com/github/ribbons/forkme_right_gray_6d6d6d.png" alt="Fork me on GitHub"></a>
+ %s
+ <script src="js/jquery-1.8.0.min.js"></script>
+ <script src="js/prettify.js"></script>
+ <script src="js/main.js"></script>
+ </body>
+</html>
Please sign in to comment.
Something went wrong with that request. Please try again.