forked from lutzroeder/netron
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
56 lines (45 loc) · 1.72 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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
build: build_python build_electron
publish: clean publish_pip publish_github_pages publish_github_electron publish_cask
install:
rm -rf ./node_modules
npm install
clean:
rm -rf ./build
build_python:
@[ -d node_modules ] || npm install
rm -rf ./build/python
python ./setup.py build
build_electron:
@[ -d node_modules ] || npm install
npx electron-builder install-app-deps
npx electron-builder --mac --linux --win
start:
@[ -d node_modules ] || npm install
npx electron .
publish_pip:
@[ -d node_modules ] || npm install
rm -rf ./build/python
python ./setup.py build bdist_wheel upload
publish_github_electron:
@[ -d node_modules ] || npm install
npx electron-builder install-app-deps
npx electron-builder --mac --linux --win --publish always --draft false --prerelease false
publish_github_pages:
@[ -d node_modules ] || npm install
python ./setup.py build
rm -rf ./build/gh-pages
git clone [email protected]:lutzroeder/Netron.git ./build/gh-pages --branch gh-pages
rm -rf ./build/gh-pages/*
cp -R ./build/python/lib/netron/* ./build/gh-pages/
rm -rf ./build/gh-pages/*.py
rm -rf ./build/gh-pages/*.pyc
rm -rf ./build/gh-pages/netron
mv ./build/gh-pages/view-browser.html ./build/gh-pages/index.html
git -C ./build/gh-pages add --all
git -C ./build/gh-pages commit --amend --no-edit
git -C ./build/gh-pages push --force origin gh-pages
publish_cask:
@curl -H "Authorization: token $(GITHUB_TOKEN)" https://api.github.com/repos/caskroom/homebrew-cask/forks -d ''
@export PACKAGE_VERSION=`node -pe "require('./package.json').version"`; \
cask-repair --cask-version $$PACKAGE_VERSION --blind-submit netron
@curl -H "Authorization: token $(GITHUB_TOKEN)" -X "DELETE" https://api.github.com/repos/lutzroeder/homebrew-cask