There are two issues here.
Exchanging file packages with people can be a challenge. You need to know what the other user's operating system can do, as well as what the other user can do. Linux, out of the box, can unpack just about anything generated on Microsoft Windows. Windows users require software in addition to the standard Windows distribution to unpack archives. You can exchange files with MacIntosh users, but you may have to install some software.
Usually, file packages are compressed, to save disk space and download time.
Tape archives were originally intended as a format for writing to magnetic tape. They are now used systematically to distribute GNU free software, usually with some sort of data compression. They are not used much outside the UNIX/Gnu world.
Create an archive called archive.tar from
foobar, which almost certainly is a directory. There
would be no point to doing this to an individual file.
Create an archive called archive.tar from the files or
directories foo, bar, barfoo and
foobar.
Create an archive called archive.tar from
foobar. The v switch means verbose output. You will
see a file listing printed to the screen as your archive is
created.
Create an archive called archive.tar from
foobar, and then compress it using Gnuzip. This works
only on systems using Gnu tar. Linux comes with Gnu tar. An
alternate file extension for Gnu zipped tar files is
*.tgz.
Write out your tar format file directly to a storage device.
On Linux, /dev/fd0 is a floppy drive. There is no need
to format the floppy. It will be in tar format. This should
work on just about any writable device other than a read-write
CD-ROM. To use a CD-ROM for backup, you will have to write
your file to a file on the hard drive, then use your CD
recording tool to transfer it to CD-ROM. To write directly
to devices, you almost certainly have to be logged in as
root.
Print out a list of the files in archive.tar.
As above, except that /dev/fd0 is a floppy disk on a
Linux box.
As above, except that this time, the tar is written to a CD-ROM.
Print out the directory of a Gnu zipped tar file. This only works on Gnu tar.
Unpack the archive foobar.tar. By unpack, I mean that
the files contained in the archive will be written out to the
current directory.
As above, but this time, print out the list of files being unpacked.
Unpack the Gnuzipped archive foobar.tgz. This only
works with Gnu tar. As noted above, a Gnuzipped tar file can
have the extension *.tar.gz. By unpack, we mean that
the files contained in the archive will we written out to the
current directory.
As above, but print the list of files being unpacked.
If you are not running Gnu tar, you do not have the z switch to activate Gnu zip. You will have to uncompress the archive with Gnu zip as a separate operation. Heck, you may have to install Gnu zip!
The command line switch dash (``-'') is optional with Gnu tar, and possibly, some of the other versions.
If you are preparing to unpack an archive, you should always check the contents to verify that it will unpack into a new subdirectory. Unpacking an archive into an existing directory that already has a lot of stuff in it usually results in a mess.
Microsoft Windows users can unpack tar files, even if they have been Gnuzipped. WINZIP supports the format. WINZIP first removes the gnuzip, providing you with the tar file. When I did this, I had to change the tar file's name from foobar_tar to foobar.tar. Then, WINZIP unpacks it.
The commands gzip, gunzip, bzip2 and bunzip2 are file compression utilities.
Compress the file foo. The compressed file will be
saved as foo.gz.
Compress the file foo. The compressed file will be
saved as foo.bz2.
Uncompress the file foo. Gzip does not require you to type in the extension.
Uncompress the file foo. Bunzip2 requires you to type in the whole filename.
Gzip and Bzip are installed with most new Linux distributions. Both are available as Gnu free software with source code. On Microsoft Windows, WINZIP can uncompress gzipped files.
The UNIX command zip manages file archives compatible
with the standard MS-DOS and Windows PKzip and WINZIP format. This
is the recommended format for exchanging archives with Microsoft
Windows users.
Get a brief description of the command zip.
Create a zip file foobar.zip from the directory
foobar.
Print out a list of the contents of foobar.zip. Always
do this before unpacking the archive. You want to know where
the files are going to be written.
Unpack the archive foobar.zip.
Pkzip is available for Linux. This is the original program for
generating *.zip archives. The program even supports
self-unpacking archives. Unfortunately, they self-unpack on Linux,
not on Windows, where you are more likely to have users without
archiving programs.
I believe this is being pushed as the latest archiving program
for Microsoft Windows. There is an unrar program for
Linux, but you may have to search for and install it.
The publisher RARLAB, has Linux and FreeBSD versions of their software. These are shareware, and you are expected to pay for a license. I have not played with them much. They provide command line help.
Historically, UNIX files were compressed using the command compress.
This might be available on your system. The compressed files
usually have the extension *.Z.
Compress the file foobar. The name will be changed to
foobar.Z.
Uncompress the file foobar.Z. The name will be changed
back to foobar. You don't have to tell compress about the file
extension.
This an important standard for distributing Linux binaries. It is quite an elaborate program. To understand it properly, you will have to read Red Hat's documentation. The following instructions will enable you to inspect, install and uninstall software from RPMs. Rpm provides quite a bit of information if you run it by itself, without operands. Most of the time, rpm will not install or uninstall software unless you are logged in as root.
List the contents of the RPM file foobar.rpm
Install the package foobar.rpm. Rpm will check your
system for dependencies before installing the package. Rpm will
refuse to install foobar if a current or later version
of foobar is already installed, or if some package
required by foobar has not already been installed.
Install the package foobar.rpm. Do not check for
dependencies. Dependency checking can be frustrating at times,
but you had had better know exactly what you are doing if you
want to skip them. You have been warned!
Remove the package foobar from your system. Again, the
dependencies are checked, and foobar will not be
removed if some other package requires it.
Be very, very careful with this. See my remarks above.
Print out brief information on package you have already installed on your system. Basically, you get the version number. Read the rpm documentation for more information on this.
Print out a list of all the packages installed by rpm.
Red Hat's yum command also installs rpm files, but it
searches for the files and dependencies out on the internet.
Slackware installs its binaries from *.tgz files which have a little
script embedded in them. You should try to use Slackware's
package manager to install these things, but tar zxf will
do in a pinch.
I have experience whatsovever with Debian packages. Sorry.
I haven't had much practise with MacIntoshes. Most Linux packages come with something called macutils, which contains things for communicating with MacIntosh computers. This could not unpack the one MacIntosh file I have received.
I had to install the package uudeview. You can get this from. http://www.uni-frankfurt.de/~fp/uudeview/ You will have to read the instructions.
Take a look at your kernel source. You can compile your kernel so that your Linux box can read MacIntosh floppies.