-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
29 lines (24 loc) · 1.05 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
CHROMIUM_BUILD_DIR = $(shell pwd)/build/chromium
FIREFOX_BUILD_DIR = $(shell pwd)/build/firefox
chromium:
npx tsc -p tsconfig.json
mkdir -p $(CHROMIUM_BUILD_DIR)/{html,css,js,img}
cp -r dist/* $(CHROMIUM_BUILD_DIR)/js
cp -r assets/* $(CHROMIUM_BUILD_DIR)/img
cp manifest.chromium.json $(CHROMIUM_BUILD_DIR)/manifest.json
cp src/html/* $(CHROMIUM_BUILD_DIR)/html
cp src/css/* $(CHROMIUM_BUILD_DIR)/css
cd $(CHROMIUM_BUILD_DIR) && (find . -type f -not -name '*.zip' | zip -@ ../$(shell basename $(CHROMIUM_BUILD_DIR))-firerss.zip)
firefox:
npx tsc -p tsconfig.json
mkdir -p $(FIREFOX_BUILD_DIR)/{html,css,js,img}
cp -r dist/* $(FIREFOX_BUILD_DIR)/js
cp -r assets/* $(FIREFOX_BUILD_DIR)/img
cp manifest.firefox.json $(FIREFOX_BUILD_DIR)/manifest.json
cp src/html/* $(FIREFOX_BUILD_DIR)/html
cp src/css/* $(FIREFOX_BUILD_DIR)/css
cd $(FIREFOX_BUILD_DIR) && (find . -type f -not -name '*.xpi' -not -name '*.zip' | zip -@ ../$(shell basename $(FIREFOX_BUILD_DIR))-firerss.xpi)
clean:
rm -rf build dist
all: chromium firefox
.PHONY: all clean chromium firefox