forked from FDOS/kernel
-
Notifications
You must be signed in to change notification settings - Fork 0
/
RELEASE.BAT
30 lines (26 loc) · 891 Bytes
/
RELEASE.BAT
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
@ECHO OFF
IF "%1"=="" GOTO USAGE
REM assume ran in root directory of kernel checkout, e.g. C:\fdos\source\kernel\
ECHO tag git with release version -
git tag -a -m "Tag kernel release %1" ke%1 HEAD
ECHO get a clean tree
if EXIST ..\SOURCE RMDIR /S /Q ..\SOURCE > NUL
::git clone -v --local --branch ke%1 . ..\SOURCE\ke%1\
git clone -v --local . ..\SOURCE\ke%1\
REM delete files to exclude
RD /S /Q ..\SOURCE\ke%1\.git > NUL
RD /S /Q ..\SOURCE\ke%1\.github > NUL
DEL /Q ..\SOURCE\ke%1\.git* > NUL
DEL /Q ..\SOURCE\ke%1\*.yml > NUL
DEL /Q ..\SOURCE\ke%1\ci*.sh > NUL
DEL /Q ..\SOURCE\ke%1\docs\*.yml > NUL
DEL /Q ..\SOURCE\ke%1\docs\CNAME > NUL
pause
ECHO %CD%
CALL MAKEPKGS.BAT %1 RELEASE
GOTO DONE
:USAGE
ECHO Tag and build release kernels - usage: RELEASE {VERSION} e.g. RELEASE 2039
:DONE
ECHO Please git push the tag to origin and upload the archives.
ECHO E.g. git push origin ke%1