mirror of
https://github.com/danog/2048.git
synced 2025-01-23 06:12:16 +01:00
add basic rake file with appcache:update task
This commit is contained in:
parent
95ca668676
commit
6a4b3ec322
11
Rakefile
Normal file
11
Rakefile
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
require "date"
|
||||||
|
|
||||||
|
namespace :appcache do
|
||||||
|
desc "update the date in the appcache file (in the gh-pages branch)"
|
||||||
|
task :update do
|
||||||
|
appcache = File.read("cache.appcache")
|
||||||
|
updated = "# Updated: #{DateTime.now}\n"
|
||||||
|
|
||||||
|
File.write("cache.appcache", appcache.sub(/\A(#.*$\n)?/, updated))
|
||||||
|
end
|
||||||
|
end
|
Loading…
x
Reference in New Issue
Block a user