mirror of
https://github.com/publiclab/mapknitter.git
synced 2025-12-05 16:00:00 +01:00
Bump image-sequencer from 1.4.1 to 3.7.2/3 and switch uglifier to terser (#1616)
* Bump image-sequencer from 1.4.1 to 3.7.2 Bumps [image-sequencer](https://github.com/publiclab/image-sequencer) from 1.4.1 to 3.7.2. - [Release notes](https://github.com/publiclab/image-sequencer/releases) - [Commits](https://github.com/publiclab/image-sequencer/compare/v1.4.1...v3.7.2) --- updated-dependencies: - dependency-name: image-sequencer dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> * removed git:// npm protocol for yarn.lock * bump image-sequencer to 3.7.3, repoint at npm * switch from uglifier to terser for better es6 support * fix require statement * updated readme * add Sprockets.register_compressor 'application/javascript', :terser, Terser::Compressor Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: jywarren <jeff@unterbahn.com>
This commit is contained in:
2
Gemfile
2
Gemfile
@@ -47,7 +47,7 @@ group :dependencies do
|
|||||||
gem 'sprockets-rails'
|
gem 'sprockets-rails'
|
||||||
gem 'sass', require: 'sass'
|
gem 'sass', require: 'sass'
|
||||||
gem 'autoprefixer-rails', '~> 10.4.2'
|
gem 'autoprefixer-rails', '~> 10.4.2'
|
||||||
gem 'uglifier', '~> 4.2.0'
|
gem 'terser', '~> 1.1.8'
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
@@ -338,6 +338,8 @@ GEM
|
|||||||
sqlite3 (1.4.2)
|
sqlite3 (1.4.2)
|
||||||
terrapin (0.6.0)
|
terrapin (0.6.0)
|
||||||
climate_control (>= 0.0.3, < 1.0)
|
climate_control (>= 0.0.3, < 1.0)
|
||||||
|
terser (1.1.8)
|
||||||
|
execjs (>= 0.3.0, < 3)
|
||||||
thor (1.2.1)
|
thor (1.2.1)
|
||||||
thread_safe (0.3.6)
|
thread_safe (0.3.6)
|
||||||
tilt (2.0.10)
|
tilt (2.0.10)
|
||||||
@@ -348,8 +350,6 @@ GEM
|
|||||||
thread_safe (~> 0.1)
|
thread_safe (~> 0.1)
|
||||||
tzinfo-data (1.2021.5)
|
tzinfo-data (1.2021.5)
|
||||||
tzinfo (>= 1.0.0)
|
tzinfo (>= 1.0.0)
|
||||||
uglifier (4.2.0)
|
|
||||||
execjs (>= 0.3.0, < 3)
|
|
||||||
unicode-display_width (2.0.0)
|
unicode-display_width (2.0.0)
|
||||||
web-console (3.7.0)
|
web-console (3.7.0)
|
||||||
actionview (>= 5.0)
|
actionview (>= 5.0)
|
||||||
@@ -424,9 +424,9 @@ DEPENDENCIES
|
|||||||
sprockets (= 3.7.2)
|
sprockets (= 3.7.2)
|
||||||
sprockets-rails
|
sprockets-rails
|
||||||
sqlite3
|
sqlite3
|
||||||
|
terser (~> 1.1.8)
|
||||||
turbolinks (~> 5)
|
turbolinks (~> 5)
|
||||||
tzinfo-data
|
tzinfo-data
|
||||||
uglifier (~> 4.2.0)
|
|
||||||
web-console (~> 3.3)
|
web-console (~> 3.3)
|
||||||
will_paginate (= 3.3.1)
|
will_paginate (= 3.3.1)
|
||||||
will_paginate-bootstrap4 (~> 0.2.2)
|
will_paginate-bootstrap4 (~> 0.2.2)
|
||||||
@@ -435,4 +435,4 @@ RUBY VERSION
|
|||||||
ruby 2.4.6p354
|
ruby 2.4.6p354
|
||||||
|
|
||||||
BUNDLED WITH
|
BUNDLED WITH
|
||||||
2.2.26
|
2.3.9
|
||||||
|
|||||||
43
README.md
43
README.md
@@ -44,11 +44,7 @@ MapKnitter is broken into three major components:
|
|||||||
|
|
||||||
**Component 2** is a Ruby on Rails application which is the core of what you've looked at. It stores images, image corner locations, annotations, map details, and user accounts.
|
**Component 2** is a Ruby on Rails application which is the core of what you've looked at. It stores images, image corner locations, annotations, map details, and user accounts.
|
||||||
|
|
||||||
**Component 3** is a set of calls to GDAL (Geospatial Data Abstraction Library) and ImageMagick, which perform the distortions, geolocations, and produce export products like GeoTiff, TMS, jpg, etc. These are baked into the Warpable and Map models, as well as the Export controller, and could use some consolidation.
|
**Component 3** is a set of calls to an external application, MapKnitter Exporter, which performs the distortions, geolocations, and produce export products like GeoTiff, TMS, jpg, etc. The external exporter service is built in a small Sinatra app at [mapknitter-exporter-sinatra](https://github.com/publiclab/mapknitter-exporter-sinatra) using the [mapknitter-exporter](https://github.com/publiclab/mapknitter-exporter) gem. Requests for exports are sent and progress is tracked using the API.
|
||||||
|
|
||||||
Component 3 is soon to be replaced with an external exporter service built in a small Sinatra app called [mapknitter-exporter-sinatra](https://github.com/publiclab/mapknitter-exporter-sinatra) using the [mapknitter-exporter](https://github.com/publiclab/mapknitter-exporter) gem.
|
|
||||||
|
|
||||||
Another moving part is the new-ish Annotations 2.0 which uses [Leaflet.Illustrate](https://github.com/manleyjster/Leaflet.Illustrate) to provide rich annotation on top of maps.
|
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
@@ -60,6 +56,15 @@ Please consider which installation method you prefer. Cloud Installation require
|
|||||||
|
|
||||||
<hr>
|
<hr>
|
||||||
|
|
||||||
|
|
||||||
|
## Cloud Installation
|
||||||
|
|
||||||
|
Cloud installation is possible with GitPod, using this link; it should be fully automated:
|
||||||
|
|
||||||
|
> https://gitpod.io/#https://github.com/publiclab/mapknitter
|
||||||
|
|
||||||
|
<hr>
|
||||||
|
|
||||||
## Standard Installation
|
## Standard Installation
|
||||||
|
|
||||||
<hr>
|
<hr>
|
||||||
@@ -170,34 +175,6 @@ http://youtu.be/iGYGpS8rZMY (may be slightly out of date, but gives an overview)
|
|||||||
|
|
||||||
<hr>
|
<hr>
|
||||||
|
|
||||||
## Cloud Installation
|
|
||||||
|
|
||||||
<hr>
|
|
||||||
|
|
||||||
We provide an install script for Codenvy's cloud service, which provides a free developer workspace server that allows anyone to contribute to a project without installing software: https://Codenvy.io.
|
|
||||||
|
|
||||||
To use it:
|
|
||||||
|
|
||||||
1. Create a personal account.
|
|
||||||
2. Click `Create new workspace`.
|
|
||||||
3. Select a new workspace with a `Rails` stack.
|
|
||||||
4. Under the `Projects` section,
|
|
||||||
add the URL of your forked version of mapknitter (`https://github.com/USERNAME/mapknitter.git`).
|
|
||||||
5. Hit create.
|
|
||||||
6. It will open in the projects explorer - use the `bash` console at the bottom of the screen to `cd` into this project's directory.
|
|
||||||
7. Run the installation script. The initial installation may take a bit.
|
|
||||||
```Bash
|
|
||||||
$ source install_cloud.sh
|
|
||||||
```
|
|
||||||
8. When you see it's complete, run the server:
|
|
||||||
```Bash
|
|
||||||
$ rails server -b 0.0.0.0
|
|
||||||
```
|
|
||||||
9. Hit the Play button located in the top menu bar.
|
|
||||||
10. Open the Codenvy URL provided in the console to see MapKnitter booted up. Great work!
|
|
||||||
|
|
||||||
<hr>
|
|
||||||
|
|
||||||
### Windows Installation
|
### Windows Installation
|
||||||
We recommend you either work in a virtual environment, or on a dual booted system to avoid dependencies issues and also Unix system works smoother with Ruby and Rails. This will not only benefit you now for Mapknitter, but also in future while working on other Ruby projects, a Linux or Mac OS will make your life easier.
|
We recommend you either work in a virtual environment, or on a dual booted system to avoid dependencies issues and also Unix system works smoother with Ruby and Rails. This will not only benefit you now for Mapknitter, but also in future while working on other Ruby projects, a Linux or Mac OS will make your life easier.
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
require 'uglifier'
|
require 'terser'
|
||||||
|
|
||||||
Rails.application.configure do
|
Rails.application.configure do
|
||||||
# Settings specified here will take precedence over those in config/application.rb.
|
# Settings specified here will take precedence over those in config/application.rb.
|
||||||
@@ -26,8 +26,8 @@ Rails.application.configure do
|
|||||||
config.public_file_server.enabled = ENV['RAILS_SERVE_STATIC_FILES'].present?
|
config.public_file_server.enabled = ENV['RAILS_SERVE_STATIC_FILES'].present?
|
||||||
|
|
||||||
# Compress JavaScripts and CSS.
|
# Compress JavaScripts and CSS.
|
||||||
config.assets.js_compressor = Uglifier.new(harmony: true, compress: { unused: false })
|
Sprockets.register_compressor 'application/javascript', :terser, Terser::Compressor
|
||||||
#config.assets.js_compressor = :uglifier
|
config.assets.js_compressor = :terser
|
||||||
# config.assets.css_compressor = :sass
|
# config.assets.css_compressor = :sass
|
||||||
|
|
||||||
# Do not fallback to assets pipeline if a precompiled asset is missed.
|
# Do not fallback to assets pipeline if a precompiled asset is missed.
|
||||||
|
|||||||
@@ -18,7 +18,7 @@
|
|||||||
"exif-js": "jseidelin/exif-js#*",
|
"exif-js": "jseidelin/exif-js#*",
|
||||||
"glfx-js": "jywarren/glfx.js#*",
|
"glfx-js": "jywarren/glfx.js#*",
|
||||||
"leaflet-google-places-autocomplete": "0.0.9",
|
"leaflet-google-places-autocomplete": "0.0.9",
|
||||||
"image-sequencer": "publiclab/image-sequencer#~1.4.0",
|
"image-sequencer": "~3.7.3",
|
||||||
"ion-rangeslider": "ionDen/ion.rangeslider#~2.3.0",
|
"ion-rangeslider": "ionDen/ion.rangeslider#~2.3.0",
|
||||||
"jquery": "jquery/jquery-dist#^3.6.0",
|
"jquery": "jquery/jquery-dist#^3.6.0",
|
||||||
"jquery-ui": "components/jqueryui#^1.12.1",
|
"jquery-ui": "components/jqueryui#^1.12.1",
|
||||||
|
|||||||
Reference in New Issue
Block a user