Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 16 additions & 16 deletions dashboard/gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import cleanCSS from "gulp-clean-css";
import { deleteAsync } from 'del';
import { exec } from 'child_process';
import { src, dest, watch, series, parallel } from "gulp";
// import header from "gulp-header";
import header from "gulp-header";
import plumber from "gulp-plumber";
import rename from "gulp-rename";
import gulpSass from 'gulp-sass';
Expand All @@ -32,16 +32,16 @@ const sass = gulpSass(s);
import uglify from "gulp-uglify";

// Load package.json for banner
// import pkg from './package.json' assert { type: "json" };
import pkg from './package.json' assert { type: "json" };

// // Set the banner content
// const banner = ['/*!\n',
// ' * Start Bootstrap - <%= pkg.title %> v<%= pkg.version %> (<%= pkg.homepage %>)\n',
// ' * Copyright 2019-' + (new Date()).getFullYear(), ' <%= pkg.author %>\n',
// ' * Licensed under <%= pkg.license %> (https://github.com/appvia/<%= pkg.name %>/blob/master/LICENSE)\n',
// ' */\n',
// '\n'
// ].join('');
// Set the banner content
const banner = ['/*!\n',
' * <%= pkg.title %> v<%= pkg.version %> (<%= pkg.homepage %>)\n',
' * Copyright 2019-' + (new Date()).getFullYear(), ' <%= pkg.author %>\n',
' * Licensed under <%= pkg.license %> (https://github.com/appvia/<%= pkg.name %>/blob/master/LICENSE)\n',
' */\n',
'\n'
].join('');

// Clean vendor
function clean() {
Expand Down Expand Up @@ -213,9 +213,9 @@ function css() {
includePaths: "./node_modules",
}))
.on("error", sass.logError)
// .pipe(header(banner, {
// pkg: pkg
// }))
.pipe(header(banner, {
pkg: pkg
}))
.pipe(dest("./compiled/css"))
.pipe(rename({
suffix: ".min"
Expand All @@ -235,9 +235,9 @@ function js() {
presets: ['@babel/preset-env']
}))
.pipe(uglify())
// .pipe(header(banner, {
// pkg: pkg
// }))
.pipe(header(banner, {
pkg: pkg
}))
.pipe(rename({
suffix: '.min'
}))
Expand Down
129 changes: 129 additions & 0 deletions dashboard/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions dashboard/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"title": "Kubernetes RBAC Inspector",
"name": "kubernetes-rbac-inspector",
"title": "Krane",
"name": "krane",
"version": "1.0.0",
"scripts": {
"start": "node_modules/.bin/gulp clean && node_modules/.bin/gulp watch",
Expand Down Expand Up @@ -35,6 +35,7 @@
"gulp-babel": "8.0.0",
"gulp-clean-css": "4.3.0",
"gulp-exec": "5.0.0",
"gulp-header": "2.0.9",
"gulp-plumber": "^1.2.1",
"gulp-rename": "2.0.0",
"gulp-sass": "^5.0.0",
Expand Down