mirror of
https://github.com/livebook-dev/livebook.git
synced 2025-02-23 22:37:41 +08:00
1. Replace `mix release mac_app|mac_app_dmg|windows_installer` with a single `mix release app` 2. Extract templates (Launcher.swift, Launcher.vbs, etc) into separate files in app_builder/lib/templates 3. Don't verify vc_redist.x64.exe checksum as the Microsoft publishes new releases on the same URL
66 lines
1.4 KiB
Elixir
66 lines
1.4 KiB
Elixir
defmodule WxDemo.MixProject do
|
|
use Mix.Project
|
|
|
|
def project do
|
|
[
|
|
app: :wx_demo,
|
|
version: "0.1.0",
|
|
elixir: "~> 1.13",
|
|
start_permanent: Mix.env() == :prod,
|
|
deps: deps(),
|
|
releases: releases()
|
|
]
|
|
end
|
|
|
|
def application do
|
|
[
|
|
extra_applications: [:wx, :logger],
|
|
mod: {WxDemo.Application, []}
|
|
]
|
|
end
|
|
|
|
defp deps do
|
|
[
|
|
{:app_builder, path: "../.."}
|
|
]
|
|
end
|
|
|
|
defp releases do
|
|
macos_notarization = macos_notarization()
|
|
|
|
[
|
|
app: [
|
|
steps: [
|
|
:assemble,
|
|
&AppBuilder.bundle/1
|
|
],
|
|
app: [
|
|
name: "WxDemo",
|
|
url_schemes: ["wxdemo"],
|
|
document_types: [
|
|
%{
|
|
name: "WxDemo",
|
|
extensions: ["wxdemo"],
|
|
macos_role: "Editor"
|
|
}
|
|
],
|
|
server: WxDemo,
|
|
macos_build_dmg: macos_notarization != nil,
|
|
macos_notarization: macos_notarization,
|
|
windows_build_installer: true
|
|
]
|
|
]
|
|
]
|
|
end
|
|
|
|
defp macos_notarization do
|
|
identity = System.get_env("NOTARIZE_IDENTITY")
|
|
team_id = System.get_env("NOTARIZE_TEAM_ID")
|
|
apple_id = System.get_env("NOTARIZE_APPLE_ID")
|
|
password = System.get_env("NOTARIZE_PASSWORD")
|
|
|
|
if identity && team_id && apple_id && password do
|
|
[identity: identity, team_id: team_id, apple_id: apple_id, password: password]
|
|
end
|
|
end
|
|
end
|