mirror of
https://github.com/prometheus/prometheus.git
synced 2024-11-09 23:24:05 -08:00
ui build: create requires web/ui/static dir ad hoc
Signed-off-by: Jan Fajerski <jfajersk@redhat.com>
This commit is contained in:
parent
dadad9bd10
commit
785d595855
3
.gitignore
vendored
3
.gitignore
vendored
|
@ -22,8 +22,7 @@ benchmark.txt
|
||||||
/documentation/examples/remote_storage/example_write_adapter/example_write_adapter
|
/documentation/examples/remote_storage/example_write_adapter/example_write_adapter
|
||||||
|
|
||||||
npm_licenses.tar.bz2
|
npm_licenses.tar.bz2
|
||||||
/web/ui/static/react-app
|
/web/ui/static
|
||||||
/web/ui/static/mantine-ui
|
|
||||||
|
|
||||||
/vendor
|
/vendor
|
||||||
/.build
|
/.build
|
||||||
|
|
|
@ -21,6 +21,7 @@ then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
buildOrder=(lezer-promql codemirror-promql)
|
buildOrder=(lezer-promql codemirror-promql)
|
||||||
|
assetsDir="./static"
|
||||||
|
|
||||||
function buildModule() {
|
function buildModule() {
|
||||||
for module in "${buildOrder[@]}"; do
|
for module in "${buildOrder[@]}"; do
|
||||||
|
@ -32,15 +33,17 @@ function buildModule() {
|
||||||
function buildReactApp() {
|
function buildReactApp() {
|
||||||
echo "build react-app"
|
echo "build react-app"
|
||||||
(cd react-app && npm run build)
|
(cd react-app && npm run build)
|
||||||
rm -rf ./static/react-app
|
mkdir -p ${assetsDir}
|
||||||
mv ./react-app/build ./static/react-app
|
rm -rf ${assetsDir}/react-app
|
||||||
|
mv ./react-app/build ${assetsDir}/react-app
|
||||||
}
|
}
|
||||||
|
|
||||||
function buildMantineUI() {
|
function buildMantineUI() {
|
||||||
echo "build mantine-ui"
|
echo "build mantine-ui"
|
||||||
npm run build -w @prometheus-io/mantine-ui
|
npm run build -w @prometheus-io/mantine-ui
|
||||||
rm -rf ./static/mantine-ui
|
mkdir -p ${assetsDir}
|
||||||
mv ./mantine-ui/dist ./static/mantine-ui
|
rm -rf ${assetsDir}/mantine-ui
|
||||||
|
mv ./mantine-ui/dist ${assetsDir}/mantine-ui
|
||||||
}
|
}
|
||||||
|
|
||||||
for i in "$@"; do
|
for i in "$@"; do
|
||||||
|
|
Loading…
Reference in a new issue