95 lines
2.3 KiB
JavaScript
95 lines
2.3 KiB
JavaScript
require('dotenv').config();
|
|
|
|
const useBootstrap = process.env.USE_BOOTSTRAP === 'true';
|
|
|
|
const stylesPath = useBootstrap
|
|
? {
|
|
source: 'source/styles/**/*.scss',
|
|
entry: 'source/styles/main.scss',
|
|
dest: 'build/styles'
|
|
}
|
|
: {
|
|
source: 'source/assets/sass/**/*.scss',
|
|
entry: 'source/assets/sass/main.scss',
|
|
dest: 'build/assets/css'
|
|
};
|
|
|
|
const scriptsPath = useBootstrap
|
|
? {
|
|
source: 'source/js/**/*.js',
|
|
entry: 'source/js/main.js',
|
|
dest: 'build/js'
|
|
}
|
|
: {
|
|
source: 'source/assets/js/**/*.js',
|
|
entry: 'source/assets/js/main.js',
|
|
dest: 'build/assets/js'
|
|
};
|
|
|
|
module.exports = {
|
|
useBootstrap,
|
|
|
|
paths: {
|
|
source: 'source',
|
|
build: 'build',
|
|
|
|
styles: stylesPath,
|
|
scripts: scriptsPath,
|
|
images: {
|
|
source: ['source/images/**/*.{jpg,jpeg,png}', 'source/assets/css/images/**/*.{jpg,jpeg,png}'],
|
|
other: ['source/images/**/*.{gif,svg,webp}', 'source/assets/css/images/**/*.{gif,svg,webp}'],
|
|
dest: 'build/images'
|
|
},
|
|
markup: {
|
|
source: ['source/**/*.{kit,html,php}'],
|
|
entry: ['source/**/*.{kit,html,php}'],
|
|
exclude: ['source/generic.html', 'source/elements.html'], // oder einzelne Dateien
|
|
dest: 'build'
|
|
},
|
|
|
|
static: {
|
|
source: [
|
|
'source/assets/**/*',
|
|
'!source/assets/sass/**/*',
|
|
'!source/assets/css/**/*.css',
|
|
'!source/assets/css/images/**/*',
|
|
'source/robots.txt'
|
|
],
|
|
dest: 'build/assets'
|
|
},
|
|
vendor: {
|
|
fontawesome: 'node_modules/@fortawesome/fontawesome-free/webfonts/*',
|
|
jquery: 'node_modules/jquery/dist/jquery.min.js',
|
|
scrollex: 'node_modules/jquery.scrollex/jquery.scrollex.min.js',
|
|
scrolly: 'node_modules/jquery.scrolly/jquery.scrolly.js',
|
|
destFonts: 'build/assets/webfonts',
|
|
destJs: 'build/assets/js'
|
|
},
|
|
favicons: {
|
|
source: ['source/*.{png,ico,svg,webmanifest}'],
|
|
dest: 'build'
|
|
}
|
|
},
|
|
|
|
extensionMapping: {
|
|
'kontakt': '.php',
|
|
'warteliste': '.php',
|
|
'400': '.shtml',
|
|
'401': '.shtml',
|
|
'403': '.shtml',
|
|
'404': '.shtml'
|
|
},
|
|
|
|
serve: {
|
|
proxy: 'https://potsdamer-reitverein.localhost',
|
|
port: 3000,
|
|
open: true
|
|
},
|
|
|
|
deploy: {
|
|
host: 'potsdamer-reitverein@10.247.64.14',
|
|
path: '/home/potsdamer-reitverein/htdocs/potsdamer-reitverein.de',
|
|
port: 2222,
|
|
excludes: ['.DS_Store', '.git']
|
|
}
|
|
}; |