compress the release zip
This commit is contained in:
parent
0f1c458e76
commit
8242ef5443
3 changed files with 1147 additions and 102 deletions
71
Gruntfile.js
71
Gruntfile.js
|
@ -128,33 +128,6 @@ module.exports = function (grunt) {
|
|||
],
|
||||
},
|
||||
},
|
||||
zip: {
|
||||
[releaseFilename]: [
|
||||
'app/**/*',
|
||||
'bin/**/*',
|
||||
'bootstrap/**/*',
|
||||
'install/**/*',
|
||||
'logs/**/',
|
||||
'resources/cache',
|
||||
'resources/sessions',
|
||||
'resources/database',
|
||||
'resources/lang/**/*',
|
||||
'resources/templates/**/*',
|
||||
'resources/schemas/**/*',
|
||||
'resources/lang/**/*',
|
||||
'resources/uploaders/**/*',
|
||||
'static/**/*',
|
||||
'vendor/**/*',
|
||||
'.htaccess',
|
||||
'config.example.php',
|
||||
'index.php',
|
||||
'composer.json',
|
||||
'composer.lock',
|
||||
'LICENSE',
|
||||
'favicon.ico',
|
||||
'CHANGELOG.md'
|
||||
]
|
||||
},
|
||||
|
||||
shell: {
|
||||
phpstan: {
|
||||
|
@ -163,7 +136,47 @@ module.exports = function (grunt) {
|
|||
composer_no_dev: {
|
||||
command: 'composer install --no-dev --prefer-dist'
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
compress: {
|
||||
main: {
|
||||
options: {
|
||||
archive: releaseFilename,
|
||||
mode: 'zip',
|
||||
level: 9,
|
||||
},
|
||||
files: [{
|
||||
expand: true,
|
||||
cwd: './',
|
||||
src: [
|
||||
'app/**/*',
|
||||
'bin/**/*',
|
||||
'bootstrap/**/*',
|
||||
'install/**/*',
|
||||
'logs/**/',
|
||||
'resources/cache',
|
||||
'resources/sessions',
|
||||
'resources/database',
|
||||
'resources/lang/**/*',
|
||||
'resources/templates/**/*',
|
||||
'resources/schemas/**/*',
|
||||
'resources/lang/**/*',
|
||||
'resources/uploaders/**/*',
|
||||
'static/**/*',
|
||||
'vendor/**/*',
|
||||
'.htaccess',
|
||||
'config.example.php',
|
||||
'index.php',
|
||||
'composer.json',
|
||||
'composer.lock',
|
||||
'LICENSE',
|
||||
'favicon.ico',
|
||||
'CHANGELOG.md'
|
||||
],
|
||||
dest: '/'
|
||||
}]
|
||||
}
|
||||
},
|
||||
|
||||
});
|
||||
|
||||
|
@ -172,5 +185,5 @@ module.exports = function (grunt) {
|
|||
grunt.registerTask('test', ['jshint']);
|
||||
grunt.registerTask('phpstan', ['shell:phpstan']);
|
||||
grunt.registerTask('composer_no_dev', ['shell:composer_no_dev']);
|
||||
grunt.registerTask('build-release', ['default', 'composer_no_dev', 'zip']);
|
||||
grunt.registerTask('build-release', ['default', 'composer_no_dev', 'compress']);
|
||||
};
|
1176
package-lock.json
generated
1176
package-lock.json
generated
File diff suppressed because it is too large
Load diff
|
@ -14,13 +14,13 @@
|
|||
},
|
||||
"devDependencies": {
|
||||
"grunt": "^1.5.3",
|
||||
"grunt-contrib-compress": "^2.0.0",
|
||||
"grunt-contrib-copy": "^1.0.0",
|
||||
"grunt-contrib-cssmin": "^3.0.0",
|
||||
"grunt-contrib-jshint": "^3.1.1",
|
||||
"grunt-contrib-uglify": "^4.0.1",
|
||||
"grunt-contrib-watch": "^1.1.0",
|
||||
"grunt-shell": "^3.0.1",
|
||||
"grunt-zip": "^0.18.2",
|
||||
"load-grunt-tasks": "^4.0.0"
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue