forked from desktop/desktop
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconveyor.conf
More file actions
123 lines (102 loc) · 4.82 KB
/
conveyor.conf
File metadata and controls
123 lines (102 loc) · 4.82 KB
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
115
116
117
118
119
120
121
122
123
// A config for Conveyor (https://conveyor.hydraulic.dev/) that creates a download site for GitHub Desktop.
// Shows how to package a real-world and sophisticated Electron app.
include required("/stdlib/electron/electron.conf")
// Import package.json files so we can avoid duplicating config. There are two in this project.
package-json {
include required("app/package.json")
}
outer-package-json {
include required("package.json")
}
// GH Desktop build system does different things and even produces different minified JS depending on the
// host platform. We could make it genuinely cross-build but it'd mean patching the Desktop build system,
// so to keep it simple we run part of the build process on CI. GH Actions doesn't make it easy to directly
// download outputs but nightly.link is here to save the day.
//
// To force a re-download of the CI build, use `conveyor make site --rerun=all`. This link could be pointed
// to a specific run ID too.
ci-artifacts-url = nightly.link/hydraulic-software/github-desktop/workflows/ci/conveyorize
// Package definition starts here.
app {
display-name = ${package-json.productName}
fsname = github-desktop // The name used for files and directories on the filesystem, when package-controllable (mostly on Linux).
license = MIT
version = 3.1.3 // Must set this explicitly because you can't use words like "beta" in version numbers.
icons = "app/static/logos/{256x256,512x512,1024x1024}.png"
contact-email = "contact@hydraulic.software"
// Avoid conflicting with the official app.
// rdns-name is a reverse DNS name that uniquely identifies this package. Needed by every platform.
rdns-name = dev.hydraulic.samples.GitHubClient
vendor = Hydraulic
// GH Desktop doesn't support Linux.
machines = [ windows.amd64, mac ]
// vcs-url = open source = free Conveyor license. Also this will set the update check URL to the latest GitHub Release.
vcs-url = "https://github.com/hydraulic-software/github-desktop"
// Publish the generated download page to GitHub Pages.
site.github.pages-branch = gh-pages
// This will control what version of Electron is downloaded and bundled.
electron.version = ${outer-package-json.devDependencies.electron}
// Files for Windows.
windows.amd64.inputs = ${ci-artifacts-url}/build-out-Windows-x64.zip
// Files for macOS.
//
// Why so complicated? GitHub Actions can only export a zip from a step, and it doesn't
// preserve UNIX metadata. So we have to wrap the Mac version in a tarball, which is
// then placed inside a zip. To support this Conveyor allows unwrapping multiple levels
// of archive with extract=2.
mac.amd64.inputs = [{
from = ${ci-artifacts-url}/build-out-macOS-x64.zip
extract = 2
}]
mac.aarch64.inputs = [{
from = ${ci-artifacts-url}/build-out-macOS-arm64.zip
extract = 2
}]
// URL handlers for logging in.
url-schemes = [
x-github-desktop-auth
x-github-desktop-dev-auth
x-github-client
github-mac
github-windows
]
// Customize Mac permission requests and integration metadata (Info.plist).
mac {
entitlements-plist."com.apple.security.automation.apple-events" = true
info-plist {
NSAppleEventsUsageDescription = GitHub Desktop uses Apple Events to implement integration features with external editors.
// Enable opening Desktop via the Finder.
CFBundleDocumentTypes = [
{
CFBundleTypeName = Folders
CFBundleTypeRole = Viewer
LSItemContentTypes = [ public.folder ]
LSHandlerRank = Alternate
}
]
LSApplicationCategoryType = public.app-category.developer-tools
NSHumanReadableCopyright = "Copyright © 2017- GitHub, Inc."
}
}
windows {
// Register a COM object that will be invoked by Windows when the user interacts with a "toast" notification for things like
// pull requests being opened, etc. See https://learn.microsoft.com/en-us/windows/apps/design/shell/tiles-and-notifications/send-local-toast-desktop-cpp-wrl#packaged
manifests.msix.extensions-xml = """
<!--Register COM CLSID LocalServer32 registry key-->
<com:Extension Category="windows.comServer">
<com:ComServer>
<com:ExeServer Executable="GitHubDesktop.exe" DisplayName="Toast activator">
<com:Class Id="27D44D0C-A542-5B90-BCDB-AC3126048BA2" DisplayName="Toast activator"/>
</com:ExeServer>
</com:ComServer>
</com:Extension>
<!--Specify which CLSID to activate when toast clicked-->
<desktop:Extension Category="windows.toastNotificationActivation">
<desktop:ToastNotificationActivation ToastActivatorCLSID="27D44D0C-A542-5B90-BCDB-AC3126048BA2" />
</desktop:Extension>
"""
}
// To do:
// - There is a CLI tool. It could be exposed by default on Windows.
}
conveyor.compatibility-level = 12