Skip to content

Commit

Permalink
Add support for YAML version file
Browse files Browse the repository at this point in the history
Created version YAML file and added support for the "version" Rake task.

depends on kronik3r#7
closes kronik3r#14
  • Loading branch information
victorbarbu committed Feb 12, 2016
1 parent 4e4c183 commit 957bf3f
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
13 changes: 12 additions & 1 deletion Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -60,4 +60,15 @@ task :post do
if File.size(filename) > 0
puts "Successfully created post file. Go edit it now!"
end
end
end

desc "Get the current version of Daktilo"
task :version do
version_file_contents = YAML.load_file(CONFIG['version_file'])

if version_file_contents['version']
puts "Daktilo version #{version_file_contents['version']}."
else
puts "Could not find version file."
end
end
1 change: 1 addition & 0 deletions _version.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
version: 1.0.0

0 comments on commit 957bf3f

Please sign in to comment.