From 36cac2f37eac09a9aadd3fefbbe919ce70fb9cce Mon Sep 17 00:00:00 2001 From: "Lincoln Baxter, III" Date: Tue, 17 Jun 2014 16:55:41 -0400 Subject: [PATCH 1/2] Add 1.x prefix to hardcoded links --- _config/site.yml | 2 +- _ext/docs.rb | 4 ++-- _layouts/base.html.haml | 30 +++++++++++++++--------------- _layouts/docs.html.haml | 8 ++++---- docs/index.html.haml | 2 +- index.html.haml | 8 ++++---- 6 files changed, 27 insertions(+), 27 deletions(-) diff --git a/_config/site.yml b/_config/site.yml index 7f42ca0..b9915cd 100644 --- a/_config/site.yml +++ b/_config/site.yml @@ -1,6 +1,6 @@ profiles: production: - base_url: http://forge.jboss.org/ + base_url: /1.x/ deploy: host: github_pages branch: master diff --git a/_ext/docs.rb b/_ext/docs.rb index 46e76bb..c2738f2 100644 --- a/_ext/docs.rb +++ b/_ext/docs.rb @@ -2,7 +2,7 @@ module Awestruct module Extensions module Docs class Index - def initialize(path_prefix='docs', assign_to=:docs) + def initialize(path_prefix='1.x/docs', assign_to=:docs) @path_prefix = path_prefix @assign_to = assign_to end @@ -26,4 +26,4 @@ def execute(site) end end end -end \ No newline at end of file +end diff --git a/_layouts/base.html.haml b/_layouts/base.html.haml index b638075..d04dc30 100644 --- a/_layouts/base.html.haml +++ b/_layouts/base.html.haml @@ -8,16 +8,16 @@ padding-top: 60px; } %script{ :type=>'text/javascript', :src=>'//cdnjs.cloudflare.com/ajax/libs/jquery/1.7.1/jquery.min.js' } - %link{ :rel=>'icon', :href=>'/images/favicon.ico' } - %link{ :rel=>'stylesheet', :type=>'text/css', :href=>'/stylesheets/styles.css' } - %link{ :rel=>'stylesheet', :type=>'text/css', :href=>'/stylesheets/bootstrap-responsive.min.css' } - %link{ :rel=>'stylesheet', :type=>'text/css', :href=>'/stylesheets/prettify.css' } + %link{ :rel=>'icon', :href=>'/1.x/images/favicon.ico' } + %link{ :rel=>'stylesheet', :type=>'text/css', :href=>'/1.x/stylesheets/styles.css' } + %link{ :rel=>'stylesheet', :type=>'text/css', :href=>'/1.x/stylesheets/bootstrap-responsive.min.css' } + %link{ :rel=>'stylesheet', :type=>'text/css', :href=>'/1.x/stylesheets/prettify.css' } /[if lt IE 9] %script{ :type=>'text/javascript', :src=>'//html5shim.googlecode.com/svn/trunk/html5.js' } - %script{ :type=>'text/javascript', :src=>'/javascripts/bootstrap.min.js' } - %script{ :type=>'text/javascript', :src=>'/javascripts/bootstrap-collapse.js' } - %script{ :type=>'text/javascript', :src=>'/javascripts/prettify.js' } - %script{ :type=>'text/javascript', :src=>'/javascripts/videoscale.js' } + %script{ :type=>'text/javascript', :src=>'/1.x/javascripts/bootstrap.min.js' } + %script{ :type=>'text/javascript', :src=>'/1.x/javascripts/bootstrap-collapse.js' } + %script{ :type=>'text/javascript', :src=>'/1.x/javascripts/prettify.js' } + %script{ :type=>'text/javascript', :src=>'/1.x/javascripts/videoscale.js' } :javascript $(document).ready(function() { $("pre.prettyprint code").removeClass("prettyprint").removeClass("linenums"); @@ -43,30 +43,30 @@ %span.icon-bar %span.icon-bar %span.icon-bar - %a.brand{ :href=>'/index.html' } - %img{ :src=>'/images/jbossforge_icon_256px.png', :alt=>'JBoss Forge', :class=>"forge-logo" } + %a.brand{ :href=>'/1.x/index.html' } + %img{ :src=>'/1.x/images/jbossforge_icon_256px.png', :alt=>'JBoss Forge', :class=>"forge-logo" } .nav-collapse %ul.nav %li - %a{ :href=>'/index.html' } Home + %a{ :href=>'/1.x/index.html' } Home %li %a{ :href=>'https://github.com/forge/core#jboss-forge-20' } Forge 2 %li - %a{ :href=>'/docs/index.html'} Documentation + %a{ :href=>'/1.x/docs/index.html'} Documentation %li - %a{ :href=>'/team.html' } Team + %a{ :href=>'/1.x/team.html' } Team %li %a{ :href=>'https://community.jboss.org/en/forge' } Forums %li %a{ :href=>'https://github.com/forge/core' } Source %li - %a{ :href=>'/plugins.html' } Plugins + %a{ :href=>'/1.x/plugins.html' } Plugins %li %a{ :target=>'issue tracker', :href=>'https://issues.jboss.org/browse/FORGE' } Issue Tracker %li %a{ :target=>'roadmap', :href=>'https://issues.jboss.org/browse/FORGE#selectedTab=com.atlassian.jira.plugin.system.project%3Aroadmap-panel' } Roadmap %li - %a{ :href=>'/events.html' } Events + %a{ :href=>'/1.x/events.html' } Events .container#content ~ content %hr diff --git a/_layouts/docs.html.haml b/_layouts/docs.html.haml index cda634c..d562c5b 100644 --- a/_layouts/docs.html.haml +++ b/_layouts/docs.html.haml @@ -9,18 +9,18 @@ layout: base %li.nav-header Using Forge - for doc in site.docs_using %li - %a{ :href=>doc.url + "#content"}= doc.title + %a{ :href=>"/1.x"+doc.url + "#content"}= doc.title %li.nav-header Get involved - for doc in site.docs_get_involved %li - %a{ :href=>doc.url + "#content"}= doc.title + %a{ :href=>"/1.x"+doc.url + "#content"}= doc.title %li.nav-header Important plugins - for doc in site.docs_important_plugins %li - %a{ :href=>doc.url + "#content"}= doc.title + %a{ :href=>"/1.x"+doc.url + "#content"}= doc.title %li.nav-header Developing plugins - for doc in site.docs_plugin_development %li - %a{ :href=>doc.url + "#content"}= doc.title + %a{ :href=>"/1.x"+doc.url + "#content"}= doc.title .span9 ~ content diff --git a/docs/index.html.haml b/docs/index.html.haml index d8ec2a2..c2e6f9a 100644 --- a/docs/index.html.haml +++ b/docs/index.html.haml @@ -27,7 +27,7 @@ layout: docs %p %h3 What should I do next? Now you are ready to -%a{:href=>"/docs/using/basic-javaee-app.html"} build an application. +%a{:href=>"/1.x/docs/using/basic-javaee-app.html"} build an application. %p .video diff --git a/index.html.haml b/index.html.haml index 0ef9687..ee7c7f9 100644 --- a/index.html.haml +++ b/index.html.haml @@ -5,7 +5,7 @@ layout: base .row{:style=>'margin-bottom: 45px;'} %p %center - %img{:src=>'/images/forge.png'} + %img{:src=>'/1.x/1.x/images/forge.png'} %center %pre .lead The fastest way to build applications, share your software, and enjoy doing it. @@ -28,7 +28,7 @@ layout: base %center %h2 The new developer evolution. %a.btn.btn-primary.btn-large{ :href =>'#', :onclick=>'_gaq.push([\'_trackEvent\', \'Downloads\', \'1.4.4.Final\']);document.location.href=\'https://repository.jboss.org/nexus/service/local/artifact/maven/redirect?r=releases&g=org.jboss.forge&a=forge-distribution&v=1.4.4.Final&e=zip\''} Download (1.4.4.Final) - %a.btn.btn-secondary.btn-large{ :href =>'/docs/'} Get Started Now! + %a.btn.btn-secondary.btn-large{ :href =>'/1.x/docs/'} Get Started Now! %p (Looking for Forge 2?) .row.visible-phone @@ -36,7 +36,7 @@ layout: base %center %h4 The new developer evolution. %a.btn.btn-primary.btn-large{ :style=>"width: 89px;", :href =>'#', :onclick=>'_gaq.push([\'_trackEvent\', \'Downloads\', \'1.4.4.Final\']);document.location.href=\'https://repository.jboss.org/nexus/service/local/artifact/maven/redirect?r=releases&g=org.jboss.forge&a=forge-distribution&v=1.4.4.Final&e=zip\''} Download (1.4.4.Final) - %a.btn.btn-secondary.btn-large{ :style=>"width: 89px;", :href =>'/docs/'} Get Started Now + %a.btn.btn-secondary.btn-large{ :style=>"width: 89px;", :href =>'/1.x/docs/'} Get Started Now %p (Looking for Forge 2?) .row @@ -75,7 +75,7 @@ layout: base - for post in site.posts %li %h3 - %a{ :href=>post.url }#{post.title} + %a{ :href=>"/1.x"+post.url }#{post.title} - if (post.content.length > 0) %p{:style=>"color: #666;"} %strong #{post.date.year}-#{post.date.month}-#{post.date.day}: #{post.author} From 618197ef42d32e93e495cee9dc58c9690a16e3b6 Mon Sep 17 00:00:00 2001 From: "Lincoln Baxter, III" Date: Wed, 18 Jun 2014 23:59:35 -0400 Subject: [PATCH 2/2] Updates for links and images --- _layouts/base.html.haml | 2 +- index.html.haml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/_layouts/base.html.haml b/_layouts/base.html.haml index d04dc30..6d8cb2b 100644 --- a/_layouts/base.html.haml +++ b/_layouts/base.html.haml @@ -50,7 +50,7 @@ %li %a{ :href=>'/1.x/index.html' } Home %li - %a{ :href=>'https://github.com/forge/core#jboss-forge-20' } Forge 2 + %a{ :href=>'/' } Forge 2 %li %a{ :href=>'/1.x/docs/index.html'} Documentation %li diff --git a/index.html.haml b/index.html.haml index ee7c7f9..05af537 100644 --- a/index.html.haml +++ b/index.html.haml @@ -5,7 +5,7 @@ layout: base .row{:style=>'margin-bottom: 45px;'} %p %center - %img{:src=>'/1.x/1.x/images/forge.png'} + %img{:src=>'/1.x/images/forge.png'} %center %pre .lead The fastest way to build applications, share your software, and enjoy doing it. @@ -29,7 +29,7 @@ layout: base %h2 The new developer evolution. %a.btn.btn-primary.btn-large{ :href =>'#', :onclick=>'_gaq.push([\'_trackEvent\', \'Downloads\', \'1.4.4.Final\']);document.location.href=\'https://repository.jboss.org/nexus/service/local/artifact/maven/redirect?r=releases&g=org.jboss.forge&a=forge-distribution&v=1.4.4.Final&e=zip\''} Download (1.4.4.Final) %a.btn.btn-secondary.btn-large{ :href =>'/1.x/docs/'} Get Started Now! - %p (Looking for Forge 2?) + %p (Looking for Forge 2?) .row.visible-phone .hero-unit