-
Notifications
You must be signed in to change notification settings - Fork 16
/
Copy pathappveyor.yml
66 lines (53 loc) · 1.89 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
environment:
PY_DIR: C:\Python36-x64
PYPI_PASSWORD:
secure: ZuRCW1W45pqH03Lio54BzQ==
GITHUB_TOKEN:
secure: Q0/Pyd8J+EX6/zaOuWATGu2OvRBLz53SYEFejI91VFiPEOJ0KbyZl+2UdYSzniDI
skip_non_tags: false
image:
- Visual Studio 2019
platform:
- x64
stack: python 3
clone_depth: 3
build: off
init:
- cmd: set PATH=C:\Program Files\Java\jdk11\bin;%PY_DIR%;%PY_DIR%\Scripts;%APPVEYOR_BUILD_FOLDER%\data\lib;%PATH%
- cmd: set CNC_INSTALL_CNCA0_CNCB0_PORTS="YES"
- cmd: set SCREEN_RECORDER_SDK_VERSION=%APPVEYOR_REPO_TAG_NAME%
- cmd: set JAVA_HOME=C:\Program Files\Java\jdk11
install:
- pip install twine
- pip install numpy==1.18.4
test_script:
- python python\setup.py install
- cd java\screen_recorder && mvn package
after_test:
- pip install wheel
- cd python && python setup.py sdist bdist_wheel
artifacts:
- path: dist
name: python_package
type: zip
deploy_script:
- ps: >-
If ($env:APPVEYOR_REPO_TAG -eq "true" -And $env:APPVEYOR_REPO_BRANCH -eq "master") {
cd $env:APPVEYOR_BUILD_FOLDER\python
twine upload --skip-existing dist/*.whl --user Andrey1994 --password $env:PYPI_PASSWORD
cd $env:APPVEYOR_BUILD_FOLDER\java\screen_recorder
(gc .\pom.xml).replace('0.0.1-SNAPSHOT',$env:APPVEYOR_REPO_TAG_NAME) | Out-File -encoding ASCII pom.xml
(gc .\settings.xml).replace('USER','Andrey1994') | Out-File -encoding ASCII settings.xml
(gc .\settings.xml).replace('TOKEN',$env:GITHUB_TOKEN) | Out-File -encoding ASCII settings.xml
mvn -s $env:APPVEYOR_BUILD_FOLDER\java\screen_recorder\settings.xml deploy -Dregistry=https://maven.pkg.github.com/Andrey1994 -Dtoken=$env:GITHUB_TOKEN
}
Else {
write-output "Skip deployment for non tag"
}
notifications:
- provider: Email
to:
on_build_success: false
on_build_failure: true
on_build_status_changed: true