Bundle all files to single JavaScript file, add development mode
This commit is contained in:
parent
820a49efd8
commit
3239a7c611
9 changed files with 194 additions and 48 deletions
15
Makefile
15
Makefile
|
@ -1,9 +1,10 @@
|
|||
.PHONY: help build clean update-npmjs-readme release publish
|
||||
.PHONY: help prod dev clean update-npmjs-readme release publish
|
||||
|
||||
help:
|
||||
@echo "Available targets:"
|
||||
@echo " - help: Show this help message"
|
||||
@echo " - build: Build the project"
|
||||
@echo " - prod: Build the project in production mode"
|
||||
@echo " - dev: Build the project in development mode"
|
||||
@echo " - clean: Remove build artifacts"
|
||||
@echo " - release: Create a new release version"
|
||||
@echo " - publish: Publish the new version created with the release target"
|
||||
|
@ -11,13 +12,17 @@ help:
|
|||
node_modules:
|
||||
npm install
|
||||
|
||||
build: node_modules
|
||||
npm run build
|
||||
prod: node_modules
|
||||
npm run prod
|
||||
|
||||
dev: node_modules
|
||||
npm run dev
|
||||
chmod +x dist/wtc-dev.mjs
|
||||
|
||||
clean:
|
||||
rm -r dist node_modules
|
||||
|
||||
release: build
|
||||
release: prod
|
||||
@read -p "Enter version bump (patch, minor, major): " bump && \
|
||||
version=$$(npm version $$bump | grep -oP "(?<=v)[^']+") && \
|
||||
echo "Version $$version created. Run 'make publish' to push the changes and publish the package."
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue