1 | SHELL := /usr/bin/env bash
|
2 |
|
3 | CDIR ?= $(shell pwd)
|
4 | CLIENT_DIR := client
|
5 | NODE_VER := $(shell cat .nvmrc)
|
6 | VOLUME_DIR := volume
|
7 |
|
8 | setup:
|
9 | @echo " 🛠 Setting environment up..."; \
|
10 | ./setup.sh ${NODE_VER};
|
11 |
|
12 | foundry:
|
13 | @echo " 📦 Fetching the app...";
|
14 | @echo " 🔗 Enter Foundry VTT build link to download: "; \
|
15 | read BUILD_ADDR; \
|
16 | curl -o FoundryVTT.zip $${BUILD_ADDR}
|
17 | unzip FoundryVTT.zip -d ${CLIENT_DIR};\
|
18 | mkdir -p ${VOLUME_DIR};
|
19 | @echo " ❗️Run this at the terminal on a fresh start:";
|
20 | @echo " . ~/.nvm/nvm.sh";
|
21 |
|
22 | launch:
|
23 | @echo " 🚀 Launching FoundryVTT..."; \
|
24 | pm2 start \
|
25 | "${CDIR}/${CLIENT_DIR}/resources/app/main.js" -- --dataPath="${CDIR}/${VOLUME_DIR}";
|