forked from FreeFeed/freefeed-react-client
-
Notifications
You must be signed in to change notification settings - Fork 0
/
winmake.cmd
50 lines (41 loc) · 763 Bytes
/
winmake.cmd
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
@echo off
set thisdir=%~dp0
set thisfile=%~f0
set out_dir=%thisdir%_dist
set public_path=/
set webpack=%thisdir%node_modules\.bin\webpack ^
--config webpack.config.js ^
--output-path %out_dir% ^
--output-public-path %public_path%
set action=%1
if "%action%"=="clean" (
echo Running %action%...
if exist %out_dir% (
rmdir /s /q %out_dir%
)
)
if "%action%"=="prod" (
echo Running %action%...
%thisfile% clean
set UGLIFY=1
set HASH=1
set DEV=0
%webpack%
)
if "%action%"=="prod-nouglify" (
echo Running %action%...
%thisfile% clean
set UGLIFY=0
set HASH=1
set DEV=0
%webpack%
)
if "%action%"=="dev" (
echo Running %action%...
%thisfile% clean
set UGLIFY=0
set HASH=0
set DEV=1
%webpack%
)
echo Done %action%.