2020-09-04 10:38:23 +00:00
|
|
|
const path = require("path");
|
2020-08-17 07:01:56 +00:00
|
|
|
|
2020-09-04 10:38:23 +00:00
|
|
|
module.exports = function (grunt) {
|
|
|
|
grunt.loadNpmTasks("grunt-contrib-copy");
|
2020-08-17 07:01:56 +00:00
|
|
|
|
|
|
|
grunt.initConfig({
|
|
|
|
// …
|
|
|
|
copy: {
|
2020-09-04 10:38:23 +00:00
|
|
|
main: {
|
|
|
|
cwd: "./node_modules/@patternfly/patternfly/assets/",
|
2020-09-23 08:05:15 +00:00
|
|
|
src: ["**/*", '!**/fontawesome/**'],
|
2020-09-04 10:38:23 +00:00
|
|
|
dest: "public/assets/",
|
|
|
|
expand: true,
|
|
|
|
},
|
|
|
|
sso: {
|
|
|
|
expand: true,
|
|
|
|
cwd: "./public/",
|
|
|
|
src: "rh-sso-*",
|
|
|
|
dest: "public",
|
|
|
|
rename: function (dest, matchedSrcPath) {
|
|
|
|
return path.join(dest, matchedSrcPath.substring("rh-sso-".length));
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
2020-08-17 07:01:56 +00:00
|
|
|
});
|
|
|
|
|
2020-09-04 10:38:23 +00:00
|
|
|
grunt.registerTask("default", ["copy:main"]);
|
|
|
|
grunt.registerTask("switch-rh-sso", ["copy:sso"]);
|
|
|
|
};
|