Skip to content

How to update openlayers

Simon Seyock edited this page Oct 15, 2018 · 11 revisions

As guide4you uses a custom version of the selectinteraction you have to choices here: Either rewrite guide4you in a way that it does not need multiple ol.interaction.Select, deselect and select methods OR you follow these steps:

  1. Clone https://github.com/KlausBenndorf/ol3
  2. Configure https://github.com/openlayers/openlayers as a remote named openlayers: git remote add openlayers https://github.com/openlayers/openlayers
  3. git checkout g4u3
  4. git pull
  5. git fetch openlayers
  6. git rebase tags/<tag> (substitute <tag> for the version you want. i.e. v3.17.1)
  7. Check if everything worked out fine: rm -rf node_modules && npm install && npm test (before v5.0.0: make clean && make check)
  8. Check if npm run dist is working correctly
  9. Commit all fixes. Do not commit dist folder.
  10. git push --force
  11. git checkout -b g4u3_<tag>
  12. rm -rf dist/ && npm run dist (before v5.0.0: make clean && make distribute (use cygwin if under windows))
  13. git add dist/ && git commit -m 'updated to <tag>' && git push -u origin g4u3_<tag>
  14. set the dependency "openlayers" to "github:KlausBenndorf/ol3#g4u3_<tag>" in the package.json of guide4you

if you want to use the new version in an linked repo, unlink repos, npm install github:KlausBenndorf/ol3#g4u3_<tag>, link repos