LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices



Reply
 
Search this Thread
Old 03-07-2004, 06:25 PM   #1
trpn
Member
 
Registered: Oct 2002
Posts: 31

Rep: Reputation: 15
tar from contents of a text file


hey

I am wondering if there is any way that I can tar files from a list of files from a text file.
so if there is a text file that contains the contents:

/etc/passwd
/etc/X11/
/var/log/

how can i pass these path names from the text file so I can put them in one tarfile using a script?
is there a way?
thanks
 
Old 03-07-2004, 07:11 PM   #2
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,004
Blog Entries: 11

Rep: Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903
Code:
man tar
/-T

Cheers,
Tink
 
Old 03-07-2004, 07:37 PM   #3
trpn
Member
 
Registered: Oct 2002
Posts: 31

Original Poster
Rep: Reputation: 15
sweet.... didn't see that in the manpage when I looked at it about 3 or 4 times!

thanks
 
Old 03-08-2004, 02:05 AM   #4
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,004
Blog Entries: 11

Rep: Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903
Anytime ;)


Cheers,
Tink
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
gave wrong syntax for tar as tar -cvzf file file.tgz how to recover the file gautham Linux - General 4 04-13-2005 04:15 AM
cutting down contents of text file kam_kenneth Linux - Newbie 2 05-22-2004 02:16 AM
How to read and change the contents of a text file? Bassam Linux - General 11 02-26-2004 05:08 AM
showing contents of a tar.Z file jpostma Linux - General 1 11-12-2003 06:14 AM
Redirecting stdout from tar to a text file. heatlill Programming 2 01-22-2002 11:27 AM


All times are GMT -5. The time now is 10:18 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration