forked from Bounz/HomeGenie-BE
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathappveyor.yml
114 lines (89 loc) · 3.92 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
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
# - Indent each level of configuration with 2 spaces. Do not use tabs!
# - All section names are case-sensitive.
version: 1.1.{build}
skip_tags: true
pull_requests:
do_not_increment_build_number: true
skip_branch_with_pr: true
branches:
only:
- master
- /V.*/
clone_folder: c:\projects\homegenie
assembly_info:
patch: true
file: '**\AssemblyInfo.*'
assembly_version: '{version}'
assembly_file_version: '{version}'
#---------------------------------#
# install configuration #
#---------------------------------#
install:
# - git clone https://github.com/Bounz/mig-service-dotnet.git
# Install innosetup
- choco install -y curl innosetup
# Install doxy
#- choco install doxygen.portable
# Download wpkg and install
- appveyor downloadfile https://downloads.sourceforge.net/project/unigw/wpkg/1.0.0/wpkg-1.0.0-amd64.exe
- wpkg-1.0.0-amd64.exe /S
# Install 7zipcommandline
- nuget install 7ZipCLI -ExcludeVersion # http://help.appveyor.com/discussions/suggestions/702-pre-install-7zipcommandline
- set PATH=%appveyor_build_folder%\packages\7ZipCLI\tools;"C:\Program Files (x86)\Inno Setup 5";%PATH%
#---------------------------------#
# build configuration #
#---------------------------------#
before_build:
- nuget restore HomeGenie_Windows\HomeGenie_VS10.sln
#build:
# project: c:\projects\homegenie\HomeGenie_Windows\HomeGenie_VS10.sln
# verbosity: minimal
build_script:
- cmd: >-
msbuild c:\projects\homegenie\BaseFiles\Windows\Windows.csproj /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll"
msbuild c:\projects\homegenie\HomeGenie_Windows\HomeGenie_VS10.sln /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll"
#---------------------------------#
# Post build steps #
#---------------------------------#
# Generate documentation
#- cd C:\projects\homegenie\Doxy
#- doxygen.exe "C:\projects\homegenie\Doxy\Doxyfile"
#- cd C:\projects\homegenie
#---------------------------------#
# pre deployment configuration #
#---------------------------------#
#before_deploy:
after_build:
- ps: . "$($env:APPVEYOR_BUILD_FOLDER)\HomeGenie_Linux\Packager\builddeb.ps1"
# Call wpkg to create .deb package
- C:\WPKG\bin\wpkg.exe --build c:\projects\homegenie\release --output-dir c:\projects\homegenie\release --verbose
#---------------------------------#
# create TGZ file #
#---------------------------------#
- 7za a -ttar "c:\projects\homegenie\release\homegenie_%APPVEYOR_BUILD_VERSION%_all.tgz" "C:\projects\homegenie\HomeGenie\bin\%CONFIGURATION%\*""
#---------------------------------#
# create windows setup (exe) file #
#---------------------------------#
- ps: (Get-Content "c:\projects\HomeGenie\HomeGenie_Windows\Packager\setup.iss") -replace "_version_", "$($env:APPVEYOR_BUILD_VERSION)" | out-file "c:\projects\HomeGenie\HomeGenie_Windows\Packager\setup.iss" -encoding ASCII -force
- iscc c:\projects\HomeGenie\HomeGenie_Windows\Packager\setup.iss /Oc:\projects\homegenie\release /Fhomegenie_%APPVEYOR_BUILD_VERSION%_all
#---------------------------------#
# Push Artifacts #
#---------------------------------#
- appveyor PushArtifact "release\homegenie_%APPVEYOR_BUILD_VERSION%_all.deb"
- appveyor PushArtifact "release\homegenie_%APPVEYOR_BUILD_VERSION%_all.tgz"
- appveyor PushArtifact "release\homegenie_%APPVEYOR_BUILD_VERSION%_all.exe"
#---------------------------------#
# Do Release #
#---------------------------------#
deploy:
release: V$(appveyor_build_version)
description: 'Homegenie (Bounz Edition) version $(appveyor_build_version)'
provider: GitHub
auth_token:
secure: MkEJm5U8V0NeUQ7cz7EcojV4XT1YUSo3gEFWrKDuoHQXx1+eTGe8l1ePdSnUivm2
# artifact: release\**\*.deb
draft: false
prerelease: true
on:
branch: master # release from master branch only
appveyor_repo_tag: false # deploy on tag push only