fixed video pattern parsing

This commit is contained in:
Heydon Pickering 2017-07-17 15:21:46 +01:00
parent a26246f890
commit 3f29f4bba1
10 changed files with 13 additions and 33 deletions

View File

@ -6,7 +6,7 @@ title = "Installation"
## Install Hugo ## Install Hugo
First we need to install Hugo globally. First you need to install Hugo globally.
### OSX users ### OSX users
@ -26,7 +26,7 @@ Installing on Windows is a bit more involved than on OSX. The authors of Hugo pr
It is likely you already have Node and NPM installed on your system. If so, you can skip this step. Otherwise, [refer to NPM's own guide](https://docs.npmjs.com/getting-started/installing-node), which includes a video tutorial. It is likely you already have Node and NPM installed on your system. If so, you can skip this step. Otherwise, [refer to NPM's own guide](https://docs.npmjs.com/getting-started/installing-node), which includes a video tutorial.
## Getting the files ## Get the files
**Infusion** is hosted on Github. To start using it, you'll need to get the files from there. If you are comfortable with the command line, just fork the [github.com/heydon/infusion](https://github.com/heydon/infusion) repository, then do a `git clone` to your local system. Replace `[your username]` in the following: **Infusion** is hosted on Github. To start using it, you'll need to get the files from there. If you are comfortable with the command line, just fork the [github.com/heydon/infusion](https://github.com/heydon/infusion) repository, then do a `git clone` to your local system. Replace `[your username]` in the following:

View File

@ -5,5 +5,5 @@ title = "Including videos"
**Infusion** has a lot of its own shortcodes, but you can still use Hugo's [built in shortcodes](https://gohugo.io/extras/shortcodes#built-in-shortcodes). These include a simple shortcode for including YouTube videos in your content. The shortcode takes just one parameter — the video's `id`. **Infusion** has a lot of its own shortcodes, but you can still use Hugo's [built in shortcodes](https://gohugo.io/extras/shortcodes#built-in-shortcodes). These include a simple shortcode for including YouTube videos in your content. The shortcode takes just one parameter — the video's `id`.
{{<codeBlock>}} {{<codeBlock>}}
&#x7b;{<youtube w7Ft2ymGmfc>}} &#x7b;{&lt;youtube w7Ft2ymGmfc>}}
{{</codeBlock>}} {{</codeBlock>}}

View File

@ -188,16 +188,6 @@ code {
padding-right: 0.25em; padding-right: 0.25em;
} }
.cmd code::after {
content: '';
display: inline-block;
width: 0.75em;
height: 1.25em;
background: #fff;
margin-left: 0.25em;
vertical-align: -0.125rem;
}
/* Lists */ /* Lists */
main ul, main ol { main ul, main ol {

View File

@ -126,7 +126,7 @@ The file tree is described using a markdown nested list structure:
<guid>https://heydon.github.io/infusion/patterns/media/including-videos/</guid> <guid>https://heydon.github.io/infusion/patterns/media/including-videos/</guid>
<description>Infusion has a lot of its own shortcodes, but you can still use Hugo&amp;rsquo;s built in shortcodes. These include a simple shortcode for including YouTube videos in your content. The shortcode takes just one parameter — the video&amp;rsquo;s id. <description>Infusion has a lot of its own shortcodes, but you can still use Hugo&amp;rsquo;s built in shortcodes. These include a simple shortcode for including YouTube videos in your content. The shortcode takes just one parameter — the video&amp;rsquo;s id.
&amp;#x7b;{}} </description> &amp;#x7b;{&amp;lt;youtube w7Ft2ymGmfc}} </description>
</item> </item>
<item> <item>
@ -136,7 +136,7 @@ The file tree is described using a markdown nested list structure:
<guid>https://heydon.github.io/infusion/patterns/installation/</guid> <guid>https://heydon.github.io/infusion/patterns/installation/</guid>
<description>Infusion is built using the static site engine, Hugo, and NPM. The codebase is available to download on Github. Let&amp;rsquo;s get set up step-by-step. <description>Infusion is built using the static site engine, Hugo, and NPM. The codebase is available to download on Github. Let&amp;rsquo;s get set up step-by-step.
Install Hugo First we need to install Hugo globally. Install Hugo First you need to install Hugo globally.
OSX users If you are a Mac user and have Homebrew on your system, installing Hugo is simple: OSX users If you are a Mac user and have Homebrew on your system, installing Hugo is simple:
brew install hugo Alternatively, you can manually install Hugo from a package. You can verify the installation was successful by typing:</description> brew install hugo Alternatively, you can manually install Hugo from a package. You can verify the installation was successful by typing:</description>
</item> </item>

View File

@ -17,7 +17,7 @@
<guid>https://heydon.github.io/infusion/patterns/installation/</guid> <guid>https://heydon.github.io/infusion/patterns/installation/</guid>
<description>Infusion is built using the static site engine, Hugo, and NPM. The codebase is available to download on Github. Let&amp;rsquo;s get set up step-by-step. <description>Infusion is built using the static site engine, Hugo, and NPM. The codebase is available to download on Github. Let&amp;rsquo;s get set up step-by-step.
Install Hugo First we need to install Hugo globally. Install Hugo First you need to install Hugo globally.
OSX users If you are a Mac user and have Homebrew on your system, installing Hugo is simple: OSX users If you are a Mac user and have Homebrew on your system, installing Hugo is simple:
brew install hugo Alternatively, you can manually install Hugo from a package. You can verify the installation was successful by typing:</description> brew install hugo Alternatively, you can manually install Hugo from a package. You can verify the installation was successful by typing:</description>
</item> </item>

View File

@ -294,8 +294,8 @@
</li> </li>
<li> <li>
<a href="#getting-the-files"> <a href="#get-the-files">
Getting the files Get the files
</a> </a>
</li> </li>
@ -310,7 +310,7 @@
<h2 id="install-hugo">Install Hugo</h2> <h2 id="install-hugo">Install Hugo</h2>
<p>First we need to install Hugo globally.</p> <p>First you need to install Hugo globally.</p>
<h3 id="osx-users">OSX users</h3> <h3 id="osx-users">OSX users</h3>
@ -332,7 +332,7 @@
<p>It is likely you already have Node and NPM installed on your system. If so, you can skip this step. Otherwise, <a href="https://docs.npmjs.com/getting-started/installing-node">refer to NPM&rsquo;s own guide</a>, which includes a video tutorial.</p> <p>It is likely you already have Node and NPM installed on your system. If so, you can skip this step. Otherwise, <a href="https://docs.npmjs.com/getting-started/installing-node">refer to NPM&rsquo;s own guide</a>, which includes a video tutorial.</p>
<h2 id="getting-the-files">Getting the files</h2> <h2 id="get-the-files">Get the files</h2>
<p><strong>Infusion</strong> is hosted on Github. To start using it, you&rsquo;ll need to get the files from there. If you are comfortable with the command line, just fork the <a href="https://github.com/heydon/infusion">github.com/heydon/infusion</a> repository, then do a <code>git clone</code> to your local system. Replace <code>[your username]</code> in the following:</p> <p><strong>Infusion</strong> is hosted on Github. To start using it, you&rsquo;ll need to get the files from there. If you are comfortable with the command line, just fork the <a href="https://github.com/heydon/infusion">github.com/heydon/infusion</a> repository, then do a <code>git clone</code> to your local system. Replace <code>[your username]</code> in the following:</p>

View File

@ -282,7 +282,7 @@
<p><strong>Infusion</strong> has a lot of its own shortcodes, but you can still use Hugo&rsquo;s <a href="https://gohugo.io/extras/shortcodes#built-in-shortcodes">built in shortcodes</a>. These include a simple shortcode for including YouTube videos in your content. The shortcode takes just one parameter — the video&rsquo;s <code>id</code>.</p> <p><strong>Infusion</strong> has a lot of its own shortcodes, but you can still use Hugo&rsquo;s <a href="https://gohugo.io/extras/shortcodes#built-in-shortcodes">built in shortcodes</a>. These include a simple shortcode for including YouTube videos in your content. The shortcode takes just one parameter — the video&rsquo;s <code>id</code>.</p>
<pre class=" "><code data-codeblock-shortcode> <pre class=" "><code data-codeblock-shortcode>
&#x7b;{<youtube w7Ft2ymGmfc>}} &#x7b;{&lt;youtube w7Ft2ymGmfc>}}
</code></pre> </code></pre>

View File

@ -27,7 +27,7 @@
<guid>https://heydon.github.io/infusion/patterns/media/including-videos/</guid> <guid>https://heydon.github.io/infusion/patterns/media/including-videos/</guid>
<description>Infusion has a lot of its own shortcodes, but you can still use Hugo&amp;rsquo;s built in shortcodes. These include a simple shortcode for including YouTube videos in your content. The shortcode takes just one parameter — the video&amp;rsquo;s id. <description>Infusion has a lot of its own shortcodes, but you can still use Hugo&amp;rsquo;s built in shortcodes. These include a simple shortcode for including YouTube videos in your content. The shortcode takes just one parameter — the video&amp;rsquo;s id.
&amp;#x7b;{}} </description> &amp;#x7b;{&amp;lt;youtube w7Ft2ymGmfc}} </description>
</item> </item>
</channel> </channel>

File diff suppressed because one or more lines are too long

View File

@ -188,16 +188,6 @@ code {
padding-right: 0.25em; padding-right: 0.25em;
} }
.cmd code::after {
content: '';
display: inline-block;
width: 0.75em;
height: 1.25em;
background: #fff;
margin-left: 0.25em;
vertical-align: -0.125rem;
}
/* Lists */ /* Lists */
main ul, main ol { main ul, main ol {