File tree Expand file tree Collapse file tree 1 file changed +21
-2
lines changed Expand file tree Collapse file tree 1 file changed +21
-2
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,26 @@ call %FUNC% GetLibName LIBNAME
12
12
call %FUNC% GetModName MODNAME
13
13
call %FUNC% SetPythonPath
14
14
call %FUNC% UsePython
15
- if exist MANIFEST ( del /q MANIFEST )
15
+ call %FUNC% GetVersion VERSION
16
+
17
+ set REPODIR = %SCRIPTPATH% \..
18
+
19
+ @ REM Clone repository in a temporary directory
20
+ set CLONEDIR = %REPODIR% \..\%LIBNAME% -tempdir
21
+ if exist %CLONEDIR% ( rmdir /s /q %CLONEDIR% )
22
+ git clone -l -s . %CLONEDIR%
23
+
24
+ @ REM Build distribution files
25
+ pushd %CLONEDIR%
16
26
%PYTHON% -m build
17
- rmdir /s /q %LIBNAME% .egg-info
27
+ popd
28
+
29
+ @ REM Copy distribution files to the repository
30
+ set DISTDIR = %REPODIR% \dist
31
+ if not exist %DISTDIR% ( mkdir %DISTDIR% )
32
+ copy /y %CLONEDIR% \dist\%MODNAME% -%VERSION% *.whl %DISTDIR%
33
+ copy /y %CLONEDIR% \dist\%MODNAME% -%VERSION% *.tar.gz %DISTDIR%
34
+
35
+ @ REM Clean up
36
+ rmdir /s /q %CLONEDIR%
18
37
call %FUNC% EndOfScript
You can’t perform that action at this time.
0 commit comments