Updated rakefile to support new directory and parsing structure.
This commit is contained in:
parent
9ac69e3091
commit
16954daa19
22
Rakefile
22
Rakefile
|
@ -148,20 +148,28 @@ namespace :site do
|
||||||
puts 'Done.'
|
puts 'Done.'
|
||||||
end
|
end
|
||||||
|
|
||||||
desc "Move the changelist over to _posts directory and update its formatting."
|
desc "Move the History.markdown over to the /docs/history directory."
|
||||||
task :changelist do
|
task :history do
|
||||||
# First lets go ahead and format the file correctly (mainly bullet points)
|
# First lets go ahead and format the file correctly (mainly bullet points)
|
||||||
|
puts "Generating the History doc!"
|
||||||
if File.exist?("History.markdown")
|
if File.exist?("History.markdown")
|
||||||
file_time = File.read("History.markdown")
|
file_time = File.read("History.markdown")
|
||||||
replaced = file_time.gsub(/\s{2}\*{1}/, "-")
|
# Replacing the contents of the file for the markdown bullets
|
||||||
# Now we need to copy the file into the _posts directory with the proper date
|
rep_bullets = file_time.gsub(/\s{2}\*{1}/, "-")
|
||||||
Dir.chdir('site/_posts') do
|
# Create a hash for the front matter that is to be included
|
||||||
sh "rm -rf *-changelist.md"
|
front_matter = {"layout" => "docs", "title" => "History",
|
||||||
File.open("#{file_date}-changelist.md", "w") {|file| file.write(replaced)}
|
"permalink" => "/docs/history/"}
|
||||||
|
# Finally we need to copy the file to the /history directory
|
||||||
|
Dir.chdir('site/docs/history') do
|
||||||
|
File.open("index.md", "w") do |file|
|
||||||
|
file.write("#{front_matter.to_yaml}---\n\n")
|
||||||
|
file.write(rep_bullets)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
puts "Uh Oh!"
|
puts "Uh Oh!"
|
||||||
end
|
end
|
||||||
|
puts "Done!"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -80,8 +80,8 @@
|
||||||
<li class="{% if page.title == "Upgrading" %}current{% endif %}">
|
<li class="{% if page.title == "Upgrading" %}current{% endif %}">
|
||||||
<a href="{{ site.url }}/docs/upgrading">Upgrading</a>
|
<a href="{{ site.url }}/docs/upgrading">Upgrading</a>
|
||||||
</li>
|
</li>
|
||||||
<li class="{% if page.title == "Changelist" %}current{% endif %}">
|
<li class="{% if page.title == "History" %}current{% endif %}">
|
||||||
<a href="{{ site.url }}/docs/changelist">Changelist</a>
|
<a href="{{ site.url }}/docs/history">History</a>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</aside>
|
</aside>
|
||||||
|
|
|
@ -1,9 +1,25 @@
|
||||||
---
|
---
|
||||||
layout: docs
|
layout: docs
|
||||||
title: Changelist
|
title: History
|
||||||
prev_section: upgrading
|
permalink: /docs/history/
|
||||||
---
|
---
|
||||||
|
|
||||||
|
## HEAD
|
||||||
|
### Major Enhancements
|
||||||
|
### Minor Enhancements
|
||||||
|
- Update pygments.rb version to 0.5.0 (#1061)
|
||||||
|
- Update Kramdown version to 1.0.2 (#1067)
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
- Catching that Redcarpet gem isn't installed (#1059)
|
||||||
|
|
||||||
|
### Site Enhancements
|
||||||
|
- Remove pygments-installation instructions, as pygments.rb is bundled with it (#1079)
|
||||||
|
- Move pages to be Pages for realz (#985)
|
||||||
|
- Updated links to Liquid documentation (#1073)
|
||||||
|
|
||||||
|
### Development Fixes
|
||||||
|
|
||||||
## 1.0.1 / 2013-05-08
|
## 1.0.1 / 2013-05-08
|
||||||
|
|
||||||
### Minor Enhancements
|
### Minor Enhancements
|
||||||
|
|
Loading…
Reference in New Issue