• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..--

README.mdD23-Jun-20251.4 KiB5242

generate-info.js.diffD23-Jun-20251.5 KiB3534

ol-layerswitcher.cssD23-Jun-20255.1 KiB189163

ol-layerswitcher.jsD23-Jun-202522.9 KiB598390

ol.cssD23-Jun-20255.3 KiB22

ol.css.mapD23-Jun-20252.6 KiB11

ol.jsD23-Jun-2025711.5 KiB

ol.js.mapD23-Jun-20254 MiB11

README.md

1# Updating libraries
2
3## update OpenLayers
4
5### full build
6This will get the full/legacy build of OpenLayers. See https://openlayers.org/download/
7
8```shell
9cd ol
10export OL_VERSION=v10.6.1
11wget https://github.com/openlayers/openlayers/releases/download/$OL_VERSION/$OL_VERSION-dist.zip
12unzip -jo $OL_VERSION-dist.zip  dist/* ol.css ol.css.map
13rm $OL_VERSION-dist.zip
14```
15
16### custom OpenLayers build
17
18A slightly more complicated build process is required to get an optimized-full-size build of OpenLayers.
19
20```shell
21cd ol
22rm -rf openlayers
23export OL_VERSION=v10.6.1
24git clone https://github.com/openlayers/openlayers.git
25cd openlayers
26git checkout -b $OL_VERSION-custom $OL_VERSION
27npm install
28# patch package.json to remove puppeteer (not supported on OpenBSD)
29npm uninstall puppeteer
30# patch generate-info.js to exclude some parts
31cp ../generate-info.js.diff .
32git apply generate-info.js.diff
33rm -rf build/
34npm run build-index
35npx rollup --config config/rollup-full-build.js
36npx cleancss --source-map src/ol/ol.css -o build/full/ol.css
37cp build/full/*.* ../
38cd ..
39rm -rf openlayers
40```
41
42## update LayerSwitcher
43
44see https://github.com/walkermatt/ol-layerswitcher#js
45
46```shell
47cd ol
48export SWITCHER_VERSION=4.1.2
49wget "https://unpkg.com/ol-layerswitcher@$SWITCHER_VERSION" -O ol-layerswitcher.js
50wget "https://unpkg.com/ol-layerswitcher@$SWITCHER_VERSION/dist/ol-layerswitcher.css" -O ol-layerswitcher.css
51```
52