Topic "Zip and Unzip files"

Author Message
imperialx

Guest


Is there a feature in WinSCP that can zip or unzip files? Thanks!
Advertisements
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
Local or remote file? For remote files you can use custom commands.
_________________
Martin Prikryl
imperialx

Guest


Hi prikryl,

Forgive me if I didn't understand your reply, are you saying that I can indeed unzip files within WinSCP remotely?

I have this scenario where I zip my files locally then upload the zipped file through WinSCP at my hoster. Once uploaded, I would like to unzipped the file within WinSCP, is this possible?

And where can I input the custom commands?

Thank you for your help.


cheers,
-imperialx
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
imperialx wrote:
Forgive me if I didn't understand your reply, are you saying that I can indeed unzip files within WinSCP remotely?

Correct. Under some circumstances.

Quote:
And where can I input the custom commands?

You will find all the details on the page linked in my previous post.
_________________
Martin Prikryl
imperialx

Guest


Hi prikryl,

There is this one list "Zip" under custom commands section with this syntax unzip "!", however, I'm getting this error "Windows cannot find 'unzip'. Make sure you typed the name correctly, and then try again."

I uploaded a zipped file (photo.zip) to remote then select the uploaded zipped file, next, using the custom command dialog, I input this custom command unzip "!" and that is how I get the error.

Did I miss anything?


Thanks,
imperialx
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
I suppose you wanted to execute the command on the server side, didn't you? So make sure to select Remote command on the custom command dialog.
_________________
Martin Prikryl
imperialx

Guest


Hi prikryl,

Under File > Custom Commands, I can't find the Remote command button.

Thanks,
imperialx
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
Please read documentation. If that does not help, come back.
_________________
Martin Prikryl
Tracster

Guest


I am trying to unzip a file on the remote site, and also get the error message "Windows cannot find unzip" after it copies the files to a temporary location.
Does this command only work on windows servers, as most servers are not run on windows?
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
Tracster wrote:
I am trying to unzip a file on the remote site, and also get the error message "Windows cannot find unzip" after it copies the files to a temporary location.
Does this command only work on windows servers, as most servers are not run on windows?

Make sure you use remote custom command. You seem to be using local custom command.
_________________
Martin Prikryl
Tomas Tobis

Guest


Hi Martin. I use WinScp in Windows style mode. I also would like to do zipping/unzipping, but it is horribly hard to do. Also the documentation you pointed to is hard to understand. Can you provide please real steps how to zip/unzip the remote file ? I mean file on FTP server I am connected to.

I tried many things, I tried to edit Custom commands, but then question appeared, how can I use them ? I tried also Commands/Open Terminal and I tried to Execute some commands. No success. I think it is time to show, how this magic really works Laughing

Tomas


P.S.: Wouldn't it be great to have context menu option for zipping/unzipping files ?
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
Tomas Tobis wrote:
Hi Martin. I use WinScp in Windows style mode. I also would like to do zipping/unzipping, but it is horribly hard to do. Also the documentation you pointed to is hard to understand. Can you provide please real steps how to zip/unzip the remote file ? I mean file on FTP server I am connected to.

The custom commands do not work with FTP. Only with SCP and possibly with SFTP.
_________________
Martin Prikryl
CoyoteKG

Guest


Hello, I'm trying to zip wordpress site over FTP, and transfer it locally.

I found this command on your documentation, but I don't know how to use it.

Code:
zip -r "!?&Enter an Archive Name:?archive.zip!" !&


Please, can you write example, like file name is just backup.zip
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
CoyoteKG wrote:
Hello, I'm trying to zip wordpress site over FTP, and transfer it locally.

I found this command on your documentation, but I don't know how to use it.

Code:
zip -r "!?&Enter an Archive Name:?archive.zip!" !&


Please, can you write example, like file name is just backup.zip

You cannot run arbitrary shell commands over FTP session. Only SFTP/SCP.
RichardHC

Guest


The easiest, fastest, best way to unzip a file on your hosting site is to be sure you zip it recursively so you have the files in their correct folders, upload it by FTP then log into your hosting service C-panel, select the file manager, go to the folder you uploaded the zip file to, select it then click on "extract" - add a path to where you want it unzipped to or just extract it into the root folder of your domain folder. Done. Easy.
Guest




RichardHC wrote:
The easiest, fastest, best way to unzip a file on your hosting site is to be sure you zip it recursively so you have the files in their correct folders, upload it by FTP then log into your hosting service C-panel, select the file manager, go to the folder you uploaded the zip file to, select it then click on "extract" - add a path to where you want it unzipped to or just extract it into the root folder of your domain folder. Done. Easy.


Six years gone and I was hoping to find some "better" solution than filezilla+cpanel for zipping/unzipping on the server but seems no way Sad((
Any good news I missed?
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
Anonymous wrote:
Six years gone and I was hoping to find some "better" solution than filezilla+cpanel for zipping/unzipping on the server but seems no way Sad((
Any good news I missed?

I believe this thread shows the way. Or what are you looking for?
Guest




thx prikryl!
I imagine an easy peasy right-click zip/unzip option (rar, gzip, etc...) Wink
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
That's it.
Just define a custom command that works on your specific server.
http://winscp.net/eng/docs/custom_commands#archiving
There's no standard solution that works everywhere.
_________________
Martin Prikryl
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License