diff --git a/build.sh b/build.sh index 1589052..b57bf0a 100755 --- a/build.sh +++ b/build.sh @@ -40,10 +40,10 @@ echo "{\"build_date\": \"$BUILD_DATE\", \"version\": \"$VERSION\", \"refresh\": cd .. echo "Done!" -echo -n "Generate cache.manifest..." - -sed "s/^\(# version\) .*$/\1 $VERSION `date +%s`/" cache.manifest-dev > cache.manifest +# cache fixes +sed -i "s/{VER}/$VERSION/" index.html +sed -i "s/{VER}/$VERSION/" service-worker.js echo "Done!" diff --git a/cache.manifest-dev b/cache.manifest-dev deleted file mode 100644 index 701d56c..0000000 --- a/cache.manifest-dev +++ /dev/null @@ -1,75 +0,0 @@ -CACHE MANIFEST -# version {VERSION} - -# gogole maps files -http://maps.google.com/maps/api/js?v=3.22&sensor=false&libraries=map,common,controls,util,marker,onion,kml,ga,infowindow,stats,poly,overlay,weather,weather_impl,geometry&language=en_us&key=AIzaSyCOqkcNey4CCyG4X0X5qxHAhCgD8g5DwXg -http://fonts.googleapis.com/css?family=Roboto:300,400,500,700 -http://maps.gstatic.com/mapfiles/undo_poly.png -http://maps.gstatic.com/mapfiles/mv/imgs8.png -http://maps.gstatic.com/mapfiles/transparent.png -http://maps.gstatic.com/mapfiles/api-3/images/mapcnt3.png -http://maps.gstatic.com/mapfiles/api-3/images/google_white2_hdpi.png -http://maps.gstatic.com/mapfiles/api-3/images/google_white2.png -http://maps.gstatic.com/mapfiles/openhand_8_8.cur - -# app files -img/closedhand.cur -img/openhand.cur -img/logo.png -img/blank.png -img/marker-you.png -img/apple-touch-icon.png -img/markers/hab_nyan.gif -img/markers/nyan.gif -img/markers/antenna-green.png -img/markers/balloon-red.png -img/markers/balloon-blue.png -img/markers/balloon-green.png -img/markers/balloon-purple.png -img/markers/balloon-cyan.png -img/markers/balloon-orange.png -img/markers/balloon-yellow.png -img/markers/balloon-rpi.png -img/markers/car-blue.png -img/markers/car-green.png -img/markers/car-red.png -img/markers/car-yellow.png -img/markers/parachute-blue.png -img/markers/parachute-green.png -img/markers/parachute-red.png -img/markers/parachute-yellow.png -img/markers/parachute-cyan.png -img/markers/parachute-orange.png -img/markers/parachute-purple.png -img/markers/parachute-rpi.png -img/markers/payload-blue.png -img/markers/payload-cyan.png -img/markers/payload-green.png -img/markers/payload-orange.png -img/markers/payload-purple.png -img/markers/payload-red.png -img/markers/payload-yellow.png -img/markers/payload-rpi.png -img/markers/shadow.png -img/markers/target-blue.png -img/markers/target-cyan.png -img/markers/target-green.png -img/markers/target-orange.png -img/markers/target-purple.png -img/markers/target-red.png -img/markers/target-yellow.png -img/hab-spinner.gif -css/mobile.css -js/mobile.js -js/init_plot.js -font/HabitatFont.eot -font/HabitatFont.svg -font/HabitatFont.ttf -font/HabitatFont.woff -font/Roboto-regular.woff - -NETWORK: -* - -FALLBACK: -/ index.html diff --git a/index.html b/index.html index 1eeadfd..21fb97c 100644 --- a/index.html +++ b/index.html @@ -414,13 +414,13 @@

Report Recovery

- - - - - - - + + + + + + + - - - + + + diff --git a/js/app.js b/js/app.js index 4ef9d1d..a0df1bb 100644 --- a/js/app.js +++ b/js/app.js @@ -1018,6 +1018,7 @@ function check_version(){ }) } function update_site(){ + window.location.reload(true) } diff --git a/service-worker.js b/service-worker.js index c00d635..fc7d456 100644 --- a/service-worker.js +++ b/service-worker.js @@ -1,6 +1,6 @@ self.addEventListener('install', function(event) { event.waitUntil( - caches.open(cacheName).then(function(cache) { + caches.open("{VER}").then(function(cache) { return cache.addAll( [ '/css/mobile.css',