mirror of https://github.com/istio/istio.io.git
Allow the site static content to be built on netlify (#3015)
This commit is contained in:
parent
51f878a914
commit
e5e8875a5e
|
@ -10,3 +10,4 @@ tmp/
|
|||
.htmlproofer
|
||||
public
|
||||
resources
|
||||
node_modules
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,29 @@
|
|||
{
|
||||
"name": "istio.io",
|
||||
"version": "1.0.0",
|
||||
"description": "This repository contains the source code for the [istio.io](https://istio.io), [preliminary.istio.io](https://preliminary.istio.io) and [archive.istio.io](https://archive.istio.io) sites.",
|
||||
"main": "index.js",
|
||||
"directories": {
|
||||
"example": "examples"
|
||||
},
|
||||
"scripts": {
|
||||
"test": "echo \"Error: no test specified\" && exit 1"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/istio/istio.io.git"
|
||||
},
|
||||
"keywords": [],
|
||||
"author": "",
|
||||
"license": "ISC",
|
||||
"bugs": {
|
||||
"url": "https://github.com/istio/istio.io/issues"
|
||||
},
|
||||
"homepage": "https://github.com/istio/istio.io#readme",
|
||||
"devDependencies": {
|
||||
"markdown-spellcheck": "^1.3.1",
|
||||
"sass": "^1.15.2",
|
||||
"svgstore-cli": "^1.3.1",
|
||||
"uglify-js": "^3.4.9"
|
||||
}
|
||||
}
|
|
@ -27,11 +27,10 @@ RUN tar -xf /tmp/hugo_${HUGO_VERSION}_Linux-64bit.tar.gz -C /tmp \
|
|||
&& rm -rf /tmp/LICENSE.md \
|
||||
&& rm -rf /tmp/README.md
|
||||
|
||||
RUN npm install -g \
|
||||
sass \
|
||||
uglify-js \
|
||||
markdown-spellcheck \
|
||||
svgstore-cli
|
||||
COPY package.json .
|
||||
COPY package-lock.json .
|
||||
|
||||
RUN npm install
|
||||
|
||||
RUN gem install \
|
||||
mdl \
|
||||
|
|
|
@ -1,18 +1,16 @@
|
|||
#!/usr/bin/env sh
|
||||
set -e
|
||||
|
||||
echo -ne "sass "
|
||||
sass --version
|
||||
uglifyjs --version
|
||||
mkdir -p static/css static/js static/img
|
||||
|
||||
sass src/sass/light_theme_archive.scss light_theme_archive.css -s compressed
|
||||
sass src/sass/light_theme_normal.scss light_theme_normal.css -s compressed
|
||||
sass src/sass/light_theme_preliminary.scss light_theme_preliminary.css -s compressed
|
||||
sass src/sass/dark_theme_archive.scss dark_theme_archive.css -s compressed
|
||||
sass src/sass/dark_theme_normal.scss dark_theme_normal.css -s compressed
|
||||
sass src/sass/dark_theme_preliminary.scss dark_theme_preliminary.css -s compressed
|
||||
npx sass src/sass/light_theme_archive.scss light_theme_archive.css -s compressed
|
||||
npx sass src/sass/light_theme_normal.scss light_theme_normal.css -s compressed
|
||||
npx sass src/sass/light_theme_preliminary.scss light_theme_preliminary.css -s compressed
|
||||
npx sass src/sass/dark_theme_archive.scss dark_theme_archive.css -s compressed
|
||||
npx sass src/sass/dark_theme_normal.scss dark_theme_normal.css -s compressed
|
||||
npx sass src/sass/dark_theme_preliminary.scss dark_theme_preliminary.css -s compressed
|
||||
mv light_theme* static/css
|
||||
mv dark_theme* static/css
|
||||
uglifyjs src/js/misc.js src/js/utils.js src/js/prism.js --mangle --compress -o static/js/all.min.js --source-map
|
||||
uglifyjs src/js/styleSwitcher.js --mangle --compress -o static/js/styleSwitcher.min.js --source-map
|
||||
svgstore -o static/img/icons.svg src/icons/**/*.svg
|
||||
npx uglifyjs src/js/misc.js src/js/utils.js src/js/prism.js --mangle --compress -o static/js/all.min.js --source-map
|
||||
npx uglifyjs src/js/styleSwitcher.js --mangle --compress -o static/js/styleSwitcher.min.js --source-map
|
||||
npx svgstore -o static/img/icons.svg src/icons/**/*.svg
|
||||
|
|
Loading…
Reference in New Issue