You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by rk...@apache.org on 2016/02/03 02:47:12 UTC
docs commit: CB-10503: Documentation link points to 'latest' version
even in latest build
Repository: cordova-docs
Updated Branches:
refs/heads/master e366a30f3 -> 715c39084
CB-10503: Documentation link points to 'latest' version even in latest build
Fixed the link to point to dev version of the docs in development. This closes #479
Project: http://git-wip-us.apache.org/repos/asf/cordova-docs/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-docs/commit/715c3908
Tree: http://git-wip-us.apache.org/repos/asf/cordova-docs/tree/715c3908
Diff: http://git-wip-us.apache.org/repos/asf/cordova-docs/diff/715c3908
Branch: refs/heads/master
Commit: 715c39084a00328b27e6968142a3b41dc5ad53f9
Parents: e366a30
Author: Sarangan Rajamanickam <sa...@microsoft.com>
Authored: Tue Feb 2 11:02:31 2016 -0800
Committer: riknoll <ri...@gmail.com>
Committed: Tue Feb 2 17:27:12 2016 -0800
----------------------------------------------------------------------
_config.yml | 5 +++++
_dev.yml | 1 +
_prod.yml | 1 +
www/_includes/header.html | 2 +-
www/index.html | 14 +++++++-------
www/plugins/authors.md | 2 +-
www/plugins/faq.md | 2 +-
www/static/plugins/pluginlist.jsx | 2 +-
8 files changed, 18 insertions(+), 11 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/715c3908/_config.yml
----------------------------------------------------------------------
diff --git a/_config.yml b/_config.yml
index b85f9f2..ca5a585 100644
--- a/_config.yml
+++ b/_config.yml
@@ -22,6 +22,11 @@ repo:
# NOTE:
# this value gets overwritten in _version.yml, which is a generated file
latest_docs_version: dev
+# NOTE:
+# this value is used to point to the documentation version to be used.
+# in development this may point to dev (in _dev.yml) and in prod this
+# may point to latest (in _prod.yml).
+default_linked_docs_version: "latest"
# NOTE:
# this value _might_ get overwritten on some pages;
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/715c3908/_dev.yml
----------------------------------------------------------------------
diff --git a/_dev.yml b/_dev.yml
index 06116fe..f5ed790 100644
--- a/_dev.yml
+++ b/_dev.yml
@@ -1,4 +1,5 @@
baseurl: ""
+default_linked_docs_version: "dev"
destination: build-dev
exclude:
- static/css-src
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/715c3908/_prod.yml
----------------------------------------------------------------------
diff --git a/_prod.yml b/_prod.yml
index 7959354..e20596a 100644
--- a/_prod.yml
+++ b/_prod.yml
@@ -1,4 +1,5 @@
baseurl: ""
+default_linked_docs_version: "latest"
destination: build-prod
exclude:
- static/css-src
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/715c3908/www/_includes/header.html
----------------------------------------------------------------------
diff --git a/www/_includes/header.html b/www/_includes/header.html
index 906a57a..ff30756 100644
--- a/www/_includes/header.html
+++ b/www/_includes/header.html
@@ -15,7 +15,7 @@
<div class="nav_bar_center">
<ul class="nav navbar-nav">
<li {% if page.docs_tab %}class="active"{% endif %}>
- <a href="{{ site.baseurl }}/docs/en/latest/guide/overview/">Documentation</a>
+ <a href="{{ site.baseurl }}/docs/en/{{ site.default_linked_docs_version }}/guide/overview/">Documentation</a>
</li>
<li {% if page.plugins_tab %}class="active"{% endif %}>
<a href="{{ site.baseurl }}/plugins">Plugins</a>
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/715c3908/www/index.html
----------------------------------------------------------------------
diff --git a/www/index.html b/www/index.html
index 32eccb5..e99bd9b 100644
--- a/www/index.html
+++ b/www/index.html
@@ -28,7 +28,7 @@ change_frequency: monthly
<a href="#getstarted" class="col-xs-12 col-sm-5 btn btn-lg btn-primary">
Get Started
</a>
- <a href="{{ site.baseurl }}/docs/en/latest/guide/overview/" class="col-xs-12 col-sm-6 btn btn-lg btn-primary">
+ <a href="{{ site.baseurl }}/docs/en/{{ site.default_linked_docs_version }}/guide/overview/" class="col-xs-12 col-sm-6 btn btn-lg btn-primary">
Documentation
</a>
</div>
@@ -76,7 +76,7 @@ change_frequency: monthly
</div>
<div class="col-md-7 col-xs-10">
<h2>Installing Cordova</h2>
- <p>Cordova command-line runs on <a target="_blank" href="http://nodejs.org/">Node.js</a> and is available on <a target="_blank" href="https://npmjs.org/package/cordova">NPM</a>. Follow <a href="{{ site.baseurl }}/docs/en/latest/guide/platforms/">platform specific guides</a> to install additional platform dependencies. Open a command prompt or Terminal, and type <code>npm install -g cordova</code>.</p>
+ <p>Cordova command-line runs on <a target="_blank" href="http://nodejs.org/">Node.js</a> and is available on <a target="_blank" href="https://npmjs.org/package/cordova">NPM</a>. Follow <a href="{{ site.baseurl }}/docs/en/{{ site.default_linked_docs_version }}/guide/platforms/">platform specific guides</a> to install additional platform dependencies. Open a command prompt or Terminal, and type <code>npm install -g cordova</code>.</p>
</div>
<div class="col-md-4 col-xs-12">
<div class="well_code">
@@ -154,16 +154,16 @@ change_frequency: monthly
<h2>Common next steps</h2>
<ul class="nav">
<li>
- <a href="{{ site.baseurl }}/docs/en/latest/guide/overview/">Read the docs</a>
+ <a href="{{ site.baseurl }}/docs/en/{{ site.default_linked_docs_version }}/guide/overview/">Read the docs</a>
</li>
<li>
- <a href="{{ site.baseurl }}/docs/en/latest/guide/cli/#link-add-plugin-features">Add a Plugin</a>
+ <a href="{{ site.baseurl }}/docs/en/{{ site.default_linked_docs_version }}/guide/cli/#link-add-plugin-features">Add a Plugin</a>
</li>
<li>
- <a href="{{ site.baseurl }}/docs/en/latest/config_ref/images.html">Add Icons and Splash Screen</a>
+ <a href="{{ site.baseurl }}/docs/en/{{ site.default_linked_docs_version }}/config_ref/images.html">Add Icons and Splash Screen</a>
</li>
<li>
- <a href="{{ site.baseurl }}/docs/en/latest/config_ref/">Configure Your App</a>
+ <a href="{{ site.baseurl }}/docs/en/{{ site.default_linked_docs_version }}/config_ref/">Configure Your App</a>
</li>
</ul>
</div>
@@ -180,7 +180,7 @@ change_frequency: monthly
<div class="col-md-12 text-center">
<h1>Supported Platforms</h1>
<h2>See a list of
- <a href="{{ site.baseurl }}/docs/en/latest/guide/support/index.html">features supported</a> in each platform</h2>
+ <a href="{{ site.baseurl }}/docs/en/{{ site.default_linked_docs_version }}/guide/support/index.html">features supported</a> in each platform</h2>
<p>
Cordova wraps your HTML/JavaScript app into a native container which can access the device functions of several platforms.
These functions are exposed via a unified JavaScript API, allowing you to easily write one set of code to target nearly every
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/715c3908/www/plugins/authors.md
----------------------------------------------------------------------
diff --git a/www/plugins/authors.md b/www/plugins/authors.md
index 5f7b7d1..bc0a567 100644
--- a/www/plugins/authors.md
+++ b/www/plugins/authors.md
@@ -40,7 +40,7 @@ Similar to `ecosystem:cordova`, platform support too uses keywords. Just add the
## Are there any additional documents to assist me with plugins?
-Yes there are. Please take a look at the [Plugin Development Guide]({{ site.baseurl }}/docs/en/latest/guide/hybrid/plugins/index.html) for a more detailed guide.
+Yes there are. Please take a look at the [Plugin Development Guide]({{ site.baseurl }}/docs/en/{{ site.default_linked_docs_version }}/guide/hybrid/plugins/index.html) for a more detailed guide.
## I don't like X. How can I help improve the website?
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/715c3908/www/plugins/faq.md
----------------------------------------------------------------------
diff --git a/www/plugins/faq.md b/www/plugins/faq.md
index e03dfac..2f0594c 100644
--- a/www/plugins/faq.md
+++ b/www/plugins/faq.md
@@ -38,7 +38,7 @@ See Cordova [blog]({{ site.baseurl }}/announcements/2015/04/21/plugins-release-a
## Are there any additional documents to assist me with plugins?
-Yes there are. Please take a look at [Add Plugin Features]({{ site.baseurl }}/docs/en/latest/guide/cli/#link-add-plugin-features) for a more detailed guide.
+Yes there are. Please take a look at [Add Plugin Features]({{ site.baseurl }}/docs/en/{{ site.default_linked_docs_version }}/guide/cli/#link-add-plugin-features) for a more detailed guide.
## I don't like X. How can I help improve the website?
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/715c3908/www/static/plugins/pluginlist.jsx
----------------------------------------------------------------------
diff --git a/www/static/plugins/pluginlist.jsx b/www/static/plugins/pluginlist.jsx
index 13f3166..8c3efc7 100755
--- a/www/static/plugins/pluginlist.jsx
+++ b/www/static/plugins/pluginlist.jsx
@@ -47,7 +47,7 @@ var PluginList = React.createClass({
if (plugins.length === 0) {
return (
<div className="container plugins-results-container">
- No plugins found. Learn how to <a href="{{site.baseurl}}/docs/en/latest/guide/hybrid/plugins/index.html">create one</a>
+ No plugins found. Learn how to <a href="{{ site.baseurl }}/docs/en/{{ site.default_linked_docs_version }}/guide/hybrid/plugins/index.html">create one</a>
</div>
);
} else {
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org