Download and unzip zip-file #3364
Answered
by
Sogl
Sogl
asked this question in
Help needed
-
Hi! My CMS it is delivered as a zip file. How to download and unzip it with Deployer task? |
Beta Was this translation helpful? Give feedback.
Answered by
Sogl
Nov 2, 2022
Replies: 2 comments 1 reply
-
Unzip |
Beta Was this translation helpful? Give feedback.
1 reply
-
Done. My task for download Grav CMS: task('grav:download_zip', function () {
// get by url
run('wget -O {{release_path}}/grav_latest.zip https://getgrav.org/download/core/grav-admin/latest');
// unzip it in same directory
run('unzip {{release_path}}/grav_latest.zip -d {{release_path}}');
// move all grav-admin files (+ dotfiles dotfolders)
run('mv {{release_path}}/grav-admin/* {{release_path}}/grav-admin/.[!.]* {{release_path}}');
// remove zip and extracted folder
run('rm -r {{release_path}}/grav_latest.zip {{release_path}}/grav-admin');
// delete all in user except plugins
run('find {{release_path}}/user -mindepth 1 -maxdepth 1 -name plugins -prune -o -exec rm -rf {} \;');
}); |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
Sogl
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Done. My task for download Grav CMS: