-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathjustfile
More file actions
114 lines (91 loc) · 5.1 KB
/
Copy pathjustfile
File metadata and controls
114 lines (91 loc) · 5.1 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
target-host := `rustc -vV | grep host: | cut -d ' ' -f 2`
target := env_var_or_default("CARGO_BUILD_TARGET", target-host)
target-os := if target =~ "-windows-" { "windows"
} else if target =~ "darwin" { "macos"
} else if target =~ "linux" { "linux"
} else { "unknown" }
target-arch := if target =~ "x86_64" { "x64"
} else if target =~ "i[56]86" { "x86"
} else if target =~ "aarch64" { "arm64"
} else if target =~ "armv7" { "arm32"
} else { "unknown" }
output-ext := if target-os == "windows" { ".exe" } else { "" }
output-filename := "midi-m8" + output-ext
build:
cargo build --release
build_plugin:
just _build_plugin
[macos]
_build_plugin:
cargo xtask bundle -p midi-m8-plugin --release
cd plugin && cargo bundle --release
[windows]
_build_plugin:
cargo xtask bundle -p midi-m8-plugin --release
[linux]
_build_plugin:
cargo xtask bundle -p midi-m8-plugin --release
package-dir:
rm -rf packages/prep
mkdir -p packages/prep
package: build build_plugin package-dir
just _package `./target/release/{{output-filename}} --version | awk '{print $2}'`
[linux]
_package version:
cp target/release/{{output-filename}} packages/prep
cd packages/prep && tar cv * | gzip -9 > "../midi-m8-{{version}}-{{target-os}}_{{target-arch}}-CLI.tgz"
@echo "Created ./packages/midi-m8-{{version}}-{{target-os}}_{{target-arch}}-CLI.tgz"
rm -r packages/prep/*
cp -r target/bundled/*.clap packages/prep
cd packages/prep && tar cv * | gzip -9 > "../midi-m8-{{version}}-{{target-os}}_{{target-arch}}-CLAP.tgz"
@echo "Created ./packages/midi-m8-{{version}}-{{target-os}}_{{target-arch}}-CLAP.tgz"
rm -r packages/prep/*
cp -r target/bundled/*.vst3 packages/prep
cd packages/prep && tar cv * | gzip -9 > "../midi-m8-{{version}}-{{target-os}}_{{target-arch}}-VST3.tgz"
@echo "Created ./packages/midi-m8-{{version}}-{{target-os}}_{{target-arch}}-VST3.tgz"
rm -r packages/prep/*
cp target/release/midi-m8-plugin packages/prep/midi-m8
cd packages/prep && tar cv * | gzip -9 > "../midi-m8-{{version}}-{{target-os}}_{{target-arch}}-STANDALONE.tgz"
@echo "Created ./packages/midi-m8-{{version}}-{{target-os}}_{{target-arch}}-STANDALONE.tgz"
[macos]
_package version:
cp target/release/{{output-filename}} packages/prep
cd packages/prep && codesign -s "$DEVELOPER_ID" --deep -v -f -o runtime *
cd packages/prep && ditto -c -k . "../midi-m8-{{version}}-{{target-os}}_{{target-arch}}-CLI.zip"
cd packages && xcrun notarytool submit *-CLI.zip --apple-id "$APPLE_ID" --team-id "$TEAM_ID" --password "$APP_PW"
@echo "Created ./packages/midi-m8-{{version}}-{{target-os}}_{{target-arch}}-CLI.zip"
rm -rf packages/prep/*
cp -r target/bundled/*.clap packages/prep
cd packages/prep && codesign -s "$DEVELOPER_ID" --deep -v -f -o runtime *
cd packages/prep && ditto -c -k . "../midi-m8-{{version}}-{{target-os}}_{{target-arch}}-CLAP.zip"
cd packages && xcrun notarytool submit *-CLAP.zip --apple-id "$APPLE_ID" --team-id "$TEAM_ID" --password "$APP_PW"
@echo "Created ./packages/midi-m8-{{version}}-{{target-os}}_{{target-arch}}-CLAP.zip"
rm -rf packages/prep/*
cp -r target/bundled/*.vst3 packages/prep
cd packages/prep && codesign -s "$DEVELOPER_ID" --deep -v -f -o runtime *
cd packages/prep && ditto -c -k . "../midi-m8-{{version}}-{{target-os}}_{{target-arch}}-VST3.zip"
cd packages && xcrun notarytool submit *-VST3.zip --apple-id "$APPLE_ID" --team-id "$TEAM_ID" --password "$APP_PW"
@echo "Created ./packages/midi-m8-{{version}}-{{target-os}}_{{target-arch}}-VST3.zip"
rm -rf packages/prep/*
cp -r target/release/bundle/osx/*.app packages/prep
cd packages/prep && codesign -s "$DEVELOPER_ID" --deep -v -f -o runtime *
cd packages/prep && ditto -c -k . "../midi-m8-{{version}}-{{target-os}}_{{target-arch}}-STANDALONE.zip"
cd packages && xcrun notarytool submit *-STANDALONE.zip --apple-id "$APPLE_ID" --team-id "$TEAM_ID" --password "$APP_PW"
@echo "Created ./packages/midi-m8-{{version}}-{{target-os}}_{{target-arch}}-STANDALONE.zip"
[windows]
_package version:
cp target/release/{{output-filename}} packages/prep
cd packages/prep && 7z a -mx9 "../midi-m8-{{version}}-{{target-os}}_{{target-arch}}-CLI.zip" *
@echo "Created ./packages/midi-m8-{{version}}-{{target-os}}_{{target-arch}}-CLI.zip"
rm -r packages/prep/*
cp -r target/bundled/*.clap packages/prep
cd packages/prep && 7z a -mx9 "../midi-m8-{{version}}-{{target-os}}_{{target-arch}}-CLAP.zip" *
@echo "Created ./packages/midi-m8-{{version}}-{{target-os}}_{{target-arch}}-CLAP.zip"
rm -r packages/prep/*
cp -r target/bundled/*.vst3 packages/prep
cd packages/prep && 7z a -mx9 "../midi-m8-{{version}}-{{target-os}}_{{target-arch}}-VST3.zip" *
@echo "Created ./packages/midi-m8-{{version}}-{{target-os}}_{{target-arch}}-VST3.zip"
rm -r packages/prep/*
cp target/release/midi-m8-plugin.exe packages/prep/midi-m8.exe
cd packages/prep && 7z a -mx9 "../midi-m8-{{version}}-{{target-os}}_{{target-arch}}-STANDALONE.zip" *
@echo "Created ./packages/midi-m8-{{version}}-{{target-os}}_{{target-arch}}-STANDALONE.zip"