2020-01-09 22:11:00 +00:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
set -euo pipefail
|
|
|
|
IFS=$'\n\t'
|
|
|
|
|
2020-09-24 12:15:37 +00:00
|
|
|
mkdir -p .storybook/resolve-imports/mediawiki.ui
|
|
|
|
mkdir -p .storybook/resolve-imports/assets
|
2020-01-09 22:11:00 +00:00
|
|
|
|
2020-09-24 12:15:37 +00:00
|
|
|
rm -f .storybook/resolve-imports/mediawiki.skin.variables.less
|
|
|
|
cp resources/mediawiki.less/mediawiki.skin.variables.less .storybook/resolve-imports/
|
2018-05-20 18:58:47 +00:00
|
|
|
|
2020-09-17 10:06:20 +00:00
|
|
|
# Fetch resources via curl, `-sSL` silently, Show only errors, Location header and also with a 3XX response code.
|
2020-05-12 16:51:49 +00:00
|
|
|
curl -sS "https://en.wikipedia.org/w/load.php?only=styles&skin=vector&debug=true&modules=ext.echo.styles.badge|ext.uls.pt|wikibase.client.init|mediawiki.skinning.interface" -o .storybook/integration.less
|
2020-09-24 12:15:37 +00:00
|
|
|
curl -sSL "https://gerrit.wikimedia.org/r/plugins/gitiles/mediawiki/core/+/master/resources/src/mediawiki.less/mediawiki.skin.defaults.less?format=TEXT" | base64 --decode > .storybook/resolve-imports/mediawiki.skin.defaults.less
|
|
|
|
curl -sSL "https://gerrit.wikimedia.org/r/plugins/gitiles/mediawiki/core/+/master/resources/src/mediawiki.less/mediawiki.mixins.less?format=TEXT" | base64 --decode > .storybook/resolve-imports/mediawiki.mixins.less
|
|
|
|
curl -sSL "https://gerrit.wikimedia.org/r/plugins/gitiles/mediawiki/core/+/master/resources/src/mediawiki.less/mediawiki.ui/variables.less?format=TEXT" | base64 --decode > .storybook/resolve-imports/mediawiki.ui/variables.less
|
|
|
|
curl -sSL "https://gerrit.wikimedia.org/r/plugins/gitiles/mediawiki/core/+/master/resources/src/mediawiki.less/mediawiki.mixins.rotation.less?format=TEXT" | base64 --decode > .storybook/resolve-imports/mediawiki.mixins.rotation.less
|
|
|
|
curl -sSL "https://gerrit.wikimedia.org/r/plugins/gitiles/mediawiki/core/+/master/resources/src/mediawiki.less/mediawiki.mixins.animation.less?format=TEXT" | base64 --decode > .storybook/resolve-imports/mediawiki.mixins.animation.less
|
|
|
|
curl -sS "https://en.m.wikipedia.org/static/images/mobile/copyright/wikipedia-wordmark-en.svg" -o ".storybook/resolve-imports/assets/wordmark.svg"
|
|
|
|
curl -sS "https://en.m.wikipedia.org/static/images/mobile/copyright/wikipedia.png" -o ".storybook/resolve-imports/assets/icon.png"
|
|
|
|
curl -sS "https://en.wikipedia.org/static/images/mobile/copyright/wikipedia-tagline-en.svg" -o ".storybook/resolve-imports/assets/tagline.svg"
|