mirror of
https://github.com/the-djmaze/snappymail.git
synced 2024-12-27 09:36:09 +08:00
Fix compressing to gzip and brotli
This commit is contained in:
parent
749fe314aa
commit
717d9208c7
1 changed files with 8 additions and 5 deletions
13
release.php
13
release.php
|
@ -21,15 +21,18 @@ if ($return_var) {
|
||||||
exit("gulp failed with error code {$return_var}\n");
|
exit("gulp failed with error code {$return_var}\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$cmddir = escapeshellcmd(__DIR__) . '/rainloop/v/0.0.0/static';
|
||||||
|
|
||||||
if ($gzip = trim(`which gzip`)) {
|
if ($gzip = trim(`which gzip`)) {
|
||||||
passthru("{$gzip} -k --best -r ".escapeshellarg(__DIR__ . '/rainloop/v/0.0.0/static/js/*.js'), $return_var);
|
passthru("{$gzip} -k --best {$cmddir}/js/*.js");
|
||||||
passthru("{$gzip} -k --best -r ".escapeshellarg(__DIR__ . '/rainloop/v/0.0.0/static/css/app*.css'), $return_var);
|
passthru("{$gzip} -k --best {$cmddir}/js/min/*.js");
|
||||||
|
passthru("{$gzip} -k --best {$cmddir}/css/app*.css");
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($brotli = trim(`which brotli`)) {
|
if ($brotli = trim(`which brotli`)) {
|
||||||
passthru("{$brotli} -k --best ".escapeshellarg(__DIR__ . '/rainloop/v/0.0.0/static/js/*.js'), $return_var);
|
passthru("{$brotli} -k --best {$cmddir}/js/*.js");
|
||||||
passthru("{$brotli} -k --best ".escapeshellarg(__DIR__ . '/rainloop/v/0.0.0/static/js/min/*.js'), $return_var);
|
passthru("{$brotli} -k --best {$cmddir}/js/min/*.js");
|
||||||
passthru("{$brotli} -k --best ".escapeshellarg(__DIR__ . '/rainloop/v/0.0.0/static/css/app*.css'), $return_var);
|
passthru("{$brotli} -k --best {$cmddir}/css/app*.css");
|
||||||
}
|
}
|
||||||
|
|
||||||
// Temporary rename folder to speed up PharData
|
// Temporary rename folder to speed up PharData
|
||||||
|
|
Loading…
Reference in a new issue