Rakefile in atome-0.5.6.4.2 vs Rakefile in atome-0.5.6.4.5
- old
+ new
@@ -181,21 +181,21 @@
puts 'atome wasm is build and running!'
threads = []
threads << Thread.new do
sleep 1
+ timestamp=Time.now.strftime("%Y%m%d%H%M%S")
if RbConfig::CONFIG['host_os'] =~ /mswin|mingw|cygwin/
# code to exec for Windows
- `start http://localhost:9292`
+ `start http://localhost:9292?date=#{timestamp}`
# `start #{destination}\\#{project_name}\\src\\index_server.html`
-
elsif RbConfig::CONFIG['host_os'] =~ /darwin|mac os/
# code to exec for MacOS
- `open http://localhost:9292`
+ `open http://localhost:9292?date=#{timestamp}`
else
# code to exec for Unix/Linux
- `open http://localhost:9292`
+ `open http://localhost:9292?date=#{timestamp}`
end
end
build_for_wasm_server(destination, project_name, 9292, :production)
@@ -223,21 +223,23 @@
# build and open the app
threads = []
threads << Thread.new do
sleep 1
+ timestamp=Time.now.strftime("%Y%m%d%H%M%S")
+
if RbConfig::CONFIG['host_os'] =~ /mswin|mingw|cygwin/
# code to exec for Windows
- `start http://localhost:9292`
+ `start http://localhost:9292?date=#{timestamp}`
# `start #{destination}\\#{project_name}\\src\\index_server.html`
elsif RbConfig::CONFIG['host_os'] =~ /darwin|mac os/
# code to exec for MacOS
- `open http://localhost:9292`
+ `open http://localhost:9292?date=#{timestamp}`
else
# code to exec for Unix/Linux
- `open http://localhost:9292`
+ `open http://localhost:9292?date=#{timestamp}`
end
end
build_for_opal_server(destination, project_name, 9292, :production)
end
@@ -266,21 +268,22 @@
# build and open the app
threads = []
threads << Thread.new do
sleep 1
+ timestamp=Time.now.strftime("%Y%m%d%H%M%S")
if RbConfig::CONFIG['host_os'] =~ /mswin|mingw|cygwin/
# code to exec for Windows
- `start http://localhost:9292`
+ `start http://localhost:9292?date=#{timestamp}`
# `start #{destination}\\#{project_name}\\src\\index_server.html`
elsif RbConfig::CONFIG['host_os'] =~ /darwin|mac os/
# code to exec for MacOS
- `open http://localhost:9292`
+ `open http://localhost:9292?date=#{timestamp}`
else
# code to exec for Unix/Linux
- `open http://localhost:9292`
+ `open http://localhost:9292?date=#{timestamp}`
end
end
# build_for_opal_server(destination, project_name, 9292, :production)
@@ -370,9 +373,13 @@
end
def gem_builder
# building the gem
+ dossier = './pkg'
+
+ # we cleanup pkg folder content
+ FileUtils.rm_rf(Dir.glob("#{dossier}/*"))
`rake build` # run build_app thru ARGV in exe atome
# installing the gem
if RbConfig::CONFIG['host_os'] =~ /mswin|mingw|cygwin/
# code to exec for Windows
`cd pkg && gem install atome --local`