1
krauh
Tar.gz Files
  • 2005/8/15 15:10

  • krauh

  • Just popping in

  • Posts: 70

  • Since: 2005/2/25


Zipped modules are easy to upload to a website after unpacking with winzip you just ftp the modules main folder.
My question is how do you upload modules that are done with a tar.gz?Winzip unpacks everything so there arent any main folders with the files neatly places in the correct order within.What do you do?

I'm new to this so explain it like i'm a caveman ok
Trying to use Xcgallery module to be exact.

Or point me to a place where theres a tutorial on this please and thanks.

2
Peekay
Re: Tar.gz Files
  • 2005/8/15 15:36

  • Peekay

  • XOOPS is my life!

  • Posts: 2335

  • Since: 2004/11/20


On my PC, I open winzip, select Open Archive and select the tar.gz. It normally says "archive contains one file, should winzip create a temporary folder and decomress it?" I say yes. You should see a list of files appear in winzip window.

Then select Actions/Extract. For safety's sake (so you don't wind up with a hundred files on your desktop) I create a temporary folder and select that as the destination. Ensure 'Use folder names' is ticked.

Some developers bury the actual module folder several layers deep, so mymodule124.tar.gz could extract to mytemporaryfolder/mymodule 1.24/html/mymodule. The last folder is the one to upload to the modules directory. It should contain a xoops_version file.

Actually, extracting tar.gz files using winzip is good, 'cos it automatically strips out erroneous line feed characters in PHP files that have been created with Linux and Mac text editors.
A thread is for life. Not just for Christmas.

3
mboyden
Re: Tar.gz Files
  • 2005/8/15 15:47

  • mboyden

  • Moderator

  • Posts: 484

  • Since: 2005/3/9 1


A couple of things to note. If you unzip the files on your desktop and then upload them to your server, they may not have the proper permissions. Better to put on your server the archive file and then unzip and untar it there. It will make life easier.

.gz is gzip (uses gunzip to unzip). It's a little different beast than zip. GZIP only compresses single files (to the best of my knowledge). To unzip the file:

gunzip filename.tar.gz

To "untar" the file:

tar -x filename.tar

However, you may want to have this in it's own directory because of how the archive was tar'ed in the first place.

Finally, a quirk if you're using Firefox, that I've experienced. When I download a .tar.gz file, it actually gunzips it upon saving it to the hard disk. I actually have a .tar file at that point (even though I saved it as a .tar.gz and there is no notice that it's being unzipped). I tore my hair out for a little while on that one.

Good luck,
Pessimists see difficulty in opportunity; Optimists see opportunity in difficulty. --W Churchill

XOOPS: Latest | Debug | Hosting and Web Development

4
Peekay
Re: Tar.gz Files
  • 2005/8/15 17:06

  • Peekay

  • XOOPS is my life!

  • Posts: 2335

  • Since: 2004/11/20


I agree decompressing on the server is better and super fast compared with uploading via FTP. But AFAIK you need shell access from your host to to unzip them in situ. Don't think you can do it via FTP?. Be interested to know. My FTP application is very old.
A thread is for life. Not just for Christmas.

5
krauh
Re: Tar.gz Files
  • 2005/8/16 3:57

  • krauh

  • Just popping in

  • Posts: 70

  • Since: 2005/2/25


Thanks for the help people

I dont have shell access
Im using free version of smartftp

I think i might have enough info here to do somethin tho thanks!

6
gravies
Re: Tar.gz Files
  • 2005/8/16 4:26

  • gravies

  • Not too shy to talk

  • Posts: 119

  • Since: 2004/8/18


I you want to unzip the file on the server you can do this little trick... create a file called untar.php with something like this...

<?php system('/usr/bin/tar xvfz /path/to/file.tgz'); ?>

If you put that file and the .tgz in the right place then it should work.

This is probably very dangerous and should not be attempted. (But I have done it).

If you use Windows you should consider installing Cygwin - it gives you a *nix shell-like environment from which you can tar, ssh, scp, rsync, etc.
Join the xoops chat lounge on irc.freenode.net #xoops or use this java clienthttp://www.hyperpod.net/modules/ircmod

7
krauh
Re: Tar.gz Files
  • 2005/8/16 4:45

  • krauh

  • Just popping in

  • Posts: 70

  • Since: 2005/2/25


Sweet

Login

Who's Online

193 user(s) are online (113 user(s) are browsing Support Forums)


Members: 0


Guests: 193


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Apr 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits