forked from tools/josh
Move build output to `dist/`
This commit is contained in:
parent
8f859a50eb
commit
2c4b1c29e5
|
@ -1,3 +1,4 @@
|
||||||
|
## Node
|
||||||
# Logs
|
# Logs
|
||||||
logs
|
logs
|
||||||
*.log
|
*.log
|
||||||
|
|
16
Gruntfile.js
16
Gruntfile.js
|
@ -4,25 +4,25 @@ module.exports = grunt => {
|
||||||
grunt.initConfig({
|
grunt.initConfig({
|
||||||
pkg: grunt.file.readJSON("package.json"),
|
pkg: grunt.file.readJSON("package.json"),
|
||||||
clean: {
|
clean: {
|
||||||
default: [".nyc_output/", "build/"]
|
default: [".nyc_output/", "dist/"]
|
||||||
},
|
},
|
||||||
copy: {
|
copy: {
|
||||||
images: {
|
images: {
|
||||||
files: [{expand: true, cwd: "src/main/", src: ["**/*.png", "**/*.ico"], dest: "build/"}]
|
files: [{expand: true, cwd: "src/main/", src: ["**/*.png", "**/*.ico"], dest: "dist/"}]
|
||||||
},
|
},
|
||||||
html: {
|
html: {
|
||||||
files: [{expand: true, cwd: "src/main/", src: "**/*.html", dest: "build/"}]
|
files: [{expand: true, cwd: "src/main/", src: "**/*.html", dest: "dist/"}]
|
||||||
},
|
},
|
||||||
css: {
|
css: {
|
||||||
files: [{expand: true, cwd: "src/main/", src: "**/*.css", dest: "build/"}]
|
files: [{expand: true, cwd: "src/main/", src: "**/*.css", dest: "dist/"}]
|
||||||
},
|
},
|
||||||
pwa: {
|
pwa: {
|
||||||
files: [{expand: true, cwd: "src/main/", src: ["manifest.json", "sw.js"], dest: "build/"}]
|
files: [{expand: true, cwd: "src/main/", src: ["manifest.json", "sw.js"], dest: "dist/"}]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
replace: {
|
replace: {
|
||||||
dev: {
|
dev: {
|
||||||
src: ["./build/*.js"],
|
src: ["./dist/*.js"],
|
||||||
replacements: [
|
replacements: [
|
||||||
{
|
{
|
||||||
from: "%%VERSION_NUMBER%%",
|
from: "%%VERSION_NUMBER%%",
|
||||||
|
@ -32,7 +32,7 @@ module.exports = grunt => {
|
||||||
overwrite: true
|
overwrite: true
|
||||||
},
|
},
|
||||||
deploy: {
|
deploy: {
|
||||||
src: ["./build/*.js"],
|
src: ["./dist/*.js"],
|
||||||
replacements: [
|
replacements: [
|
||||||
{
|
{
|
||||||
from: "%%VERSION_NUMBER%%",
|
from: "%%VERSION_NUMBER%%",
|
||||||
|
@ -59,7 +59,7 @@ module.exports = grunt => {
|
||||||
},
|
},
|
||||||
output: {
|
output: {
|
||||||
filename: "bundle.js",
|
filename: "bundle.js",
|
||||||
path: path.resolve(__dirname, "build/"),
|
path: path.resolve(__dirname, "dist/"),
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
dev: {
|
dev: {
|
||||||
|
|
|
@ -13,9 +13,9 @@ $> npm ci
|
||||||
|
|
||||||
### Building
|
### Building
|
||||||
```shell script
|
```shell script
|
||||||
# Build the application in `build/` for development
|
# Build the application in `dist/` for development
|
||||||
$> npm run dev
|
$> npm run dev
|
||||||
# Build the application in `build/` for deployment
|
# Build the application in `dist/` for deployment
|
||||||
$> npm run deploy
|
$> npm run deploy
|
||||||
# Remove build files
|
# Remove build files
|
||||||
$> npm run clean
|
$> npm run clean
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
{
|
{
|
||||||
"name": "fwdekker.com",
|
"name": "fwdekker.com",
|
||||||
"version": "0.33.7",
|
"version": "0.33.8",
|
||||||
"description": "The source code of [my personal website](https://fwdekker.com/).",
|
"description": "The source code of [my personal website](https://fwdekker.com/).",
|
||||||
"author": "Felix W. Dekker",
|
"author": "Felix W. Dekker",
|
||||||
"browser": "bundle.js",
|
"browser": "dist/bundle.js",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "git@git.fwdekker.com:FWDekker/fwdekker.com.git"
|
"url": "git@git.fwdekker.com:FWDekker/fwdekker.com.git"
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
"target": "es2019",
|
"target": "es2019",
|
||||||
"strict": true,
|
"strict": true,
|
||||||
"rootDir": "./src/main/js/",
|
"rootDir": "./src/main/js/",
|
||||||
"outDir": "./build/js/"
|
"outDir": "./dist/js/"
|
||||||
},
|
},
|
||||||
"include": [
|
"include": [
|
||||||
"src/main/js/**/*.ts"
|
"src/main/js/**/*.ts"
|
||||||
|
|
Loading…
Reference in New Issue