Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
66de5374
Commit
66de5374
authored
Mar 04, 2015
by
Steve Dower
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add scripts for uploading Windows builds to a Linux server using pscp
parent
65b20bf8
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
108 additions
and
0 deletions
+108
-0
Tools/msi/buildrelease.bat
Tools/msi/buildrelease.bat
+1
-0
Tools/msi/uploadrelease.bat
Tools/msi/uploadrelease.bat
+46
-0
Tools/msi/uploadrelease.proj
Tools/msi/uploadrelease.proj
+61
-0
No files found.
Tools/msi/buildrelease.bat
View file @
66de5374
...
...
@@ -140,6 +140,7 @@ if not "%OUTDIR%" EQU "" (
copy
/Y
"
%BUILD%
en-us\*.cab"
"
%OUTDIR%
\
%OUTDIR_PLAT%
"
copy
/Y
"
%BUILD%
en-us\*.exe"
"
%OUTDIR%
\
%OUTDIR_PLAT%
"
copy
/Y
"
%BUILD%
en-us\*.msi"
"
%OUTDIR%
\
%OUTDIR_PLAT%
"
copy
/Y
"
%BUILD%
en-us\*.msu"
"
%OUTDIR%
\
%OUTDIR_PLAT%
"
)
exit
/B
0
...
...
Tools/msi/uploadrelease.bat
0 → 100644
View file @
66de5374
@setlocal
@echo
off
set
D
=
%~dp0
set
PCBUILD
=
%D%
..\..\PCBuild\
set
HOST
=
set
USER
=
set
TARGET
=
set
DRYRUN
=
false
:CheckOpts
if
"
%
1"
EQU
"-h"
goto
Help
if
"
%
1"
EQU
"-o"
(
set
HOST
=
%
~
2
)
&&
shift
&&
shift
&&
goto
CheckOpts
if
"
%
1"
EQU
"--host"
(
set
HOST
=
%
~
2
)
&&
shift
&&
shift
&&
goto
CheckOpts
if
"
%
1"
EQU
"-u"
(
set
USER
=
%
~
2
)
&&
shift
&&
shift
&&
goto
CheckOpts
if
"
%
1"
EQU
"--user"
(
set
USER
=
%
~
2
)
&&
shift
&&
shift
&&
goto
CheckOpts
if
"
%
1"
EQU
"-t"
(
set
TARGET
=
%
~
2
)
&&
shift
&&
shift
&&
goto
CheckOpts
if
"
%
1"
EQU
"--target"
(
set
TARGET
=
%
~
2
)
&&
shift
&&
shift
&&
goto
CheckOpts
if
"
%
1"
EQU
"--dry-run"
(
set
DRYRUN
=
true
)
&&
shift
&&
goto
CheckOpts
if
not
defined
PLINK
where
plink
>
"
%TEMP%
\plink.loc"
2
>
nul
&&
set
/P
PLINK
=
<
"
%TEMP%
\plink.loc"
&
del
"
%TEMP%
\plink.loc"
if
not
defined
PLINK
where
/R
"
%ProgramFiles
(x86)
%
"
plink
>
"
%TEMP%
\plink.loc"
2
>
nul
&&
set
/P
PLINK
=
<
"
%TEMP%
\plink.loc"
&
del
"
%TEMP%
\plink.loc"
if
not
defined
PLINK
echo
Cannot
locate
plink
.exe
&
exit
/B
1
echo
Found
plink
.exe
at
%PLINK%
if
not
defined
PSCP
where
pscp
>
"
%TEMP%
\pscp.loc"
2
>
nul
&&
set
/P
pscp
=
<
"
%TEMP%
\pscp.loc"
&
del
"
%TEMP%
\pscp.loc"
if
not
defined
PSCP
where
/R
"
%ProgramFiles
(x86)
%
"
pscp
>
"
%TEMP%
\pscp.loc"
2
>
nul
&&
set
/P
pscp
=
<
"
%TEMP%
\pscp.loc"
&
del
"
%TEMP%
\pscp.loc"
if
not
defined
PSCP
echo
Cannot
locate
pscp
.exe
&
exit
/B
1
echo
Found
pscp
.exe
at
%PSCP%
call
"
%PCBUILD%
env.bat"
>
nul
2
>
nul
msbuild
/v
:m
/nologo
uploadrelease
.proj
/t
:Upload
/p
:Platform
=
x86
msbuild
/v
:m
/nologo
uploadrelease
.proj
/t
:Upload
/p
:Platform
=
x64
/p
:IncludeDoc
=
false
exit
/B
0
:Help
echo
uploadrelease
.bat
-
-host
HOST
-
-user
USERNAME
[-
-target
TARGET
]
[-
-dry-run
]
[
-h
]
echo
.
echo
-
-host
(
-o
)
Specify
the
upload
host
(
required
)
echo
-
-user
(
-u
)
Specify
the
user
on
the
host
(
required
)
echo
-
-target
(
-t
)
Specify
the
target
directory
on
the
host
echo
-
-dry-run
Display
commands
and
filenames
without
executing
them
echo
-h
Display
this
help
information
echo
.
Tools/msi/uploadrelease.proj
0 → 100644
View file @
66de5374
<?xml version="1.0" encoding="utf-8"?>
<Project
ToolsVersion=
"4.0"
DefaultTargets=
"Build"
xmlns=
"http://schemas.microsoft.com/developer/msbuild/2003"
>
<PropertyGroup>
<ProjectGuid>
{2D69F2AB-D5D0-4344-84B5-EF6DB34A9BC9}
</ProjectGuid>
<OutputName>
python
</OutputName>
<OutputSuffix></OutputSuffix>
<DownloadUrlBase
Condition=
"'$(DownloadUrlBase)' == ''"
>
$(TARGET)
</DownloadUrlBase>
<DownloadUrlBase
Condition=
"'$(DownloadUrlBase)' == ''"
>
/srv/www.python.org/ftp/python
</DownloadUrlBase>
<IncludeDoc
Condition=
"'$(IncludeDoc)' == ''"
>
true
</IncludeDoc>
<DryRun
Condition=
"'$(DryRun)' == ''"
>
false
</DryRun>
</PropertyGroup>
<Import
Project=
"msi.props"
/>
<Import
Project=
"bundle\bundle.targets"
/>
<PropertyGroup>
<EXETarget>
$(DownloadUrlBase.TrimEnd(`/`))/$(MajorVersionNumber).$(MinorVersionNumber).$(MicroVersionNumber)
</EXETarget>
<MSITarget>
$(DownloadUrl.TrimEnd(`/`))
</MSITarget>
</PropertyGroup>
<ItemGroup>
<File
Include=
"$(OutputPath)\*.msi;$(OutputPath)\*.msu"
>
<CopyTo>
$(MSITarget)
</CopyTo>
</File>
<File
Include=
"$(OutputPath)\*.exe"
>
<CopyTo>
$(EXETarget)
</CopyTo>
</File>
<File
Include=
"$(PySourcePath)Doc\build\htmlhelp\python$(MajorVersionNumber)$(MinorVersionNumber)$(MicroVersionNumber)$(ReleaseLevelName).chm"
Condition=
"$(IncludeDoc)"
>
<CopyTo>
$(EXETarget)
</CopyTo>
</File>
</ItemGroup>
<Target
Name=
"_ValidateProperties"
>
<Error
Text=
"No value for Host provided"
Condition=
"'$(Host)' == ''"
/>
<Error
Text=
"No value for User provided"
Condition=
"'$(User)' == ''"
/>
<Error
Text=
"No path for PSCP provided"
Condition=
"'$(PSCP)' == ''"
/>
<Error
Text=
"No path for PLINK provided"
Condition=
"'$(PLINK)' == ''"
/>
</Target>
<Target
Name=
"_Upload"
Condition=
"!$(DryRun)"
>
<Exec
Command=
""$(PLINK)" $(User)@$(Host) mkdir %(File.CopyTo) ^&^& chgrp downloads %(File.CopyTo) ^&^& chmod g-w,o+rx %(File.CopyTo)
"$(PSCP)" @(File,' ') $(User)@$(Host):%(File.CopyTo)
"$(PLINK)" $(User)@$(Host) chgrp downloads %(File.CopyTo)/* ^&^& chmod g-w,o+r %(File.CopyTo)/*
"
/>
</Target>
<Target
Name=
"_PrintNames"
Condition=
"$(DryRun)"
>
<Exec
Command=
"echo "$(PLINK)" $(User)@$(Host) mkdir %(File.CopyTo) ^&^& chgrp downloads %(File.CopyTo) ^&^& chmod g-w,o+rx %(File.CopyTo)
echo "$(PSCP)" @(File,' ') $(User)@$(Host):%(File.CopyTo)
echo "$(PLINK)" $(User)@$(Host) chgrp downloads %(File.CopyTo)/* ^&^& chmod g-w,o+r %(File.CopyTo)/*
echo.
echo."
/>
</Target>
<Target
Name=
"Upload"
DependsOnTargets=
"_ValidateProperties;_PrintNames;_Upload"
/>
<Target
Name=
"Build"
>
<Error
Text=
"This script should be invoked using uploadrelease.bat."
/>
</Target>
</Project>
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment