mirror of
https://github.com/fog/fog.git
synced 2022-11-09 13:51:43 -05:00
[core] more consistent redirector for fog.io
This commit is contained in:
parent
e0b8606d85
commit
3fde14cafa
1 changed files with 13 additions and 1 deletions
14
Rakefile
14
Rakefile
|
@ -204,9 +204,21 @@ task :docs do
|
|||
)
|
||||
end
|
||||
|
||||
redirecter = <<-HTML
|
||||
<!doctype html>
|
||||
<head>
|
||||
<title>fog</title>
|
||||
<meta http-equiv="REFRESH" content="0;url=http://fog.io/#{version}">
|
||||
</head>
|
||||
<body>
|
||||
<a href="http://fog.io/#{version}">redirecting to lastest version => fog #{version}</a>
|
||||
</body>
|
||||
</html>
|
||||
HTML
|
||||
|
||||
# write base index with redirect to new version
|
||||
directory.files.create(
|
||||
:body => '<!doctype html><head><script>window.location = "http://fog.io/' << version << '"</script></head></html>',
|
||||
:body => redirecter,
|
||||
:content_type => 'text/html',
|
||||
:key => 'index.html',
|
||||
:public => true
|
||||
|
|
Loading…
Reference in a new issue