2018-12-05 09:32:49 +03:00
|
|
|
#!/bin/bash
|
2018-12-04 00:56:10 +03:00
|
|
|
set -e
|
2018-12-05 09:32:49 +03:00
|
|
|
|
2018-12-01 03:29:31 +03:00
|
|
|
if [ -z "$NOW_TOKEN" ]; then
|
|
|
|
echo "NOW_TOKEN is not set; skipping docs deployment"
|
|
|
|
else
|
2018-12-05 12:41:19 +03:00
|
|
|
cp modules/primer/build/build.css docs/static/primer.css
|
2018-12-04 00:56:10 +03:00
|
|
|
cd docs
|
2018-12-05 12:41:19 +03:00
|
|
|
now --token=$NOW_TOKEN | tee now-url.txt
|
2018-12-05 09:32:49 +03:00
|
|
|
url=$(cat now-url.txt)
|
2018-12-05 12:54:51 +03:00
|
|
|
version=$(jq -r .version ../modules/primer/package.json)
|
|
|
|
npx commit-status success docs "deployed primer@$version to $url" "$url"
|
2018-12-01 03:29:31 +03:00
|
|
|
fi
|