forked from Homebrew/homebrew-cask
-
Notifications
You must be signed in to change notification settings - Fork 0
/
adobe-illustrator-cc.rb
142 lines (109 loc) · 2.32 KB
/
adobe-illustrator-cc.rb
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
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
cask 'adobe-illustrator-cc' do
version '19'
sha256 'ca3e059b130e0b9a6c56ae55b89fa4d490650e25a9371072f43285c10c9821d2'
language 'cs' do
'cs_CZ'
end
language 'da' do
'da_DK'
end
language 'de' do
'de_DE'
end
language 'en-AE' do
'en_AE'
end
language 'en-GB' do
'en_GB'
end
language 'en-IL' do
'en_IL'
end
language 'en' do
'en_US'
end
language 'es-MX' do
'es_MX'
end
language 'es' do
'es_ES'
end
language 'fi' do
'fi_FI'
end
language 'fr-CA' do
'fr_CA'
end
language 'fr-MA' do
'fr_MA'
end
language 'fr' do
'fr_FR'
end
language 'hu' do
'hu_HU'
end
language 'it' do
'it_IT'
end
language 'ja' do
'ja_JP'
end
language 'ko' do
'ko_KR'
end
language 'nb' do
'nb_NO'
end
language 'nl' do
'nl_NL'
end
language 'pl' do
'pl_PL'
end
language 'pt' do
'pt_BR'
end
language 'ru' do
'ru_RU'
end
language 'sv' do
'sv_SE'
end
language 'tr' do
'tr_TR'
end
language 'uk' do
'uk_UA'
end
language 'zh-TW' do
'zh_TW'
end
language 'zh' do
'zh_CN'
end
url "http:https://trials3.adobe.com/AdobeProducts/ILST/#{version}/osx10-64/Illustrator_#{version.major}_LS20.dmg",
user_agent: :fake,
cookies: { 'MM_TRIALS' => '1234' }
name 'Adobe Illustrator CC'
homepage 'https://www.adobe.com/products/illustrator.html'
preflight do
deployment_xml = "#{staged_path}/Adobe Illustrator CC 2015/Deployment/deployment.xml"
IO.write deployment_xml, IO.read(deployment_xml).sub(%r{>en_US<}, ">#{language}<")
system_command "#{staged_path}/Adobe Illustrator CC 2015/Install.app/Contents/MacOS/Install",
args: [
'--mode=silent',
"--deploymentFile=#{deployment_xml}",
],
sudo: true
end
uninstall_preflight do
system_command "#{staged_path}/Adobe Illustrator CC 2015/Install.app/Contents/MacOS/Install",
args: [
'--mode=silent',
"--deploymentFile=#{staged_path}/Adobe\ Illustrator\ CC\ 2015/Deployment/uninstall.xml",
],
sudo: true
end
uninstall rmdir: '/Applications/Utilities/Adobe Installers'
end