forked from bleachbit/bleachbit
-
Notifications
You must be signed in to change notification settings - Fork 0
/
appveyor.yml
99 lines (87 loc) · 4.2 KB
/
appveyor.yml
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
build: off
version: 4.2.0.{build}
image: Visual Studio 2013
environment:
PYTHON_HOME: 'C:/Python34'
SZ_EXE : '"C:/Program Files/7-Zip/7z.exe"'
make : 'C:/MinGW/bin/mingw32-make.exe'
init:
- 'systeminfo | findstr /B /C:"OS Name" /C:"OS Version"' # show Windows version
- 'echo PYTHON_HOME=%PYTHON_HOME%'
- '%PYTHON_HOME%/python.exe -V' # show Python version
- '%PYTHON_HOME%/Scripts/pip.exe --version' # show pip version
- 'set PIP_DEFAULT_TIMEOUT=180'
install:
- '%PYTHON_HOME%/Scripts/pip.exe install https://download.bleachbit.org/appveyor/psutil-5.6.7-cp34-cp34m-win32.whl'
- '%PYTHON_HOME%/Scripts/pip.exe install https://download.bleachbit.org/appveyor/pywin32-227-cp34-cp34m-win32.whl'
- '%PYTHON_HOME%/Scripts/pip.exe install pypiwin32'
- '%PYTHON_HOME%/Scripts/pip.exe install winshell'
- '%PYTHON_HOME%/Scripts/pip.exe install pefile cachetools' # for py2exe
- '%PYTHON_HOME%/Scripts/pip.exe install py2exe'
- '%PYTHON_HOME%/Scripts/pip.exe install scandir'
- '%PYTHON_HOME%/Scripts/pip.exe install chardet'
- '%PYTHON_HOME%/Scripts/pip.exe install requests'
- '%PYTHON_HOME%/Scripts/pip.exe install plyer'
- '%PYTHON_HOME%/Scripts/pip.exe install win-unicode-console'
- ps: if (-not (Test-Path pygi-aio.exe )) { Start-FileDownload "https://sourceforge.net/projects/pygobjectwin32/files/pygi-aio-3.24.1_rev1-setup_049a323fe25432b10f7e9f543b74598d4be74a39.exe/download" -FileName pygi-aio.exe}
- ps: Get-FileHash pygi-aio.exe
- 'pygi-aio.exe %PYTHON_HOME% GTK'
- ps: if (-not (Test-Path upx.zip)) { Start-FileDownload "https://github.com/upx/upx/releases/download/v3.96/upx-3.96-win64.zip" -FileName upx.zip}
- ps: Get-FileHash upx.zip
- '%SZ_EXE% x upx.zip'
- 'rename upx-3.96-win64 upx'
- 'dir .\upx\'
- ps: if (-not (Test-Path gettext.zip)) { Start-FileDownload "https://github.com/mlocati/gettext-iconv-windows/releases/download/v0.21-v1.16/gettext0.21-iconv1.16-static-32.zip" -FileName gettext.zip}
- ps: Get-FileHash gettext.zip
- '%SZ_EXE% x gettext.zip -ogettext'
- ps: if (-not (Test-Path sqlite.zip)) { Start-FileDownload "https://sqlite.org/2020/sqlite-dll-win32-x86-3340000.zip" -FileName sqlite.zip }
- ps: Get-FileHash sqlite.zip -Algorithm SHA1
- '%SZ_EXE% x sqlite.zip'
- 'move /y sqlite3.dll %PYTHON_HOME%\DLLs\'
# - ps: if (-not (Test-Path vcredist_x86.exe)) { Start-FileDownload "https://download.microsoft.com/download/5/B/C/5BC5DBB3-652D-4DCE-B14A-475AB85EEF6E/vcredist_x86.exe" -FileName vcredist_x86.exe }
- 'set PATH=%PATH%;%cd%\gettext\bin;C:\MinGW\bin;'
# Show version numbers of installed software.
- 'msgunfmt -V'
- 'strip.exe -V'
- '"c:\Program Files (x86)\NSIS\makensis.exe" /version'
build_script:
- ps: $env:REV8 = $env:APPVEYOR_REPO_COMMIT.Substring(0,8)
- 'echo revision = "%REV8%" > bleachbit\Revision.py'
- 'echo build_number = "%APPVEYOR_BUILD_NUMBER%" > bleachbit\Revision.py'
- '%make% -C po local'
- '%PYTHON_HOME%/python.exe -m windows.setup_py2exe'
- 'move windows\BleachBit*.exe .'
- 'move windows\BleachBit*.zip .'
- ps: Get-FileHash BleachBit-*
cache:
- pygi-aio.exe -> appveyor.yml
- upx.zip -> appveyor.yml
- gettext.zip -> appveyor.yml
- sqlite.zip -> appveyor.yml
test_script:
# coveralls.io
- '%PYTHON_HOME%/Scripts/pip.exe install python-coveralls requests[security]'
# shorten very long path because of error https://github.com/az0/bleachbit/issues/166
- 'set PATH=c:\windows\system32;c:\windows;c:\windows\system32\wbem;c:\windows\SysWOW64\WindowsPowerShell\v1.0\'
- '%PYTHON_HOME%/Scripts/pip.exe install mock'
- 'SET DESTRUCTIVE_TESTS=T'
- '%PYTHON_HOME%/Scripts/coverage.exe run --include="bleachbit/*" -m unittest discover -v -p Test*.py'
artifacts:
- path: BleachBit-*-setup.exe
name: FullInstaller
- path: BleachBit-*-setup-English.exe
name: EnglishInstaller
- path: BleachBit-*-portable.zip
name: Portable
- path: .coverage
deploy:
- provider: S3
access_key_id:
secure: CrPvjz7Jvg4gwOHKxUsL0PPR4mqAjB2p15/pvFw3fCk=
secret_access_key:
secure: VoAH5pVyhmTK3/KRuV5WcgfkTR3k/M9QDt7UD6ewcwNfkUvMynwjAHnKCG4vR0Rx
bucket: bleachbitci
folder: dl/$(APPVEYOR_BUILD_VERSION)-$(APPVEYOR_REPO_BRANCH)
artifact:
set-public: true
reduced_redundancy: true