Ken Moffat wrote:
> 2009/9/12 Dan McGhee <[email protected]>:
>
>
>   
>> This little script works for both *.gz and *.bz2 files. If anyone wants
>> to use it, please do. The only problem comes when "untarring" an archive
>> that doesn't create a directory with the package name. For example,
>> vim-7.2.tar.bz2 creates "vim72." I can let the script abort, change
>> $packagedir and let it run again.
>>
>> But if someone can figure a way to "script around this," I sure would
>> like to hear about it. I've been working on this for a couple of days
>> and want to get started on my build.
>>
>>     
>
> DIRECTORY=`tar -tv $TARCMD -f ${PACKAGES}/${CURRENT}  | head -n 1 |
> awk '{ print $6}' | sed s'@^./@@' | \
>                 cut -d '/' -f 1`
> if [ -z $DIRECTORY ]; then
> echo "indentify: error in trying to determine directory name"
>                 exit 1
> fi
>
>
>   
Oh brother, thanks again. Can I have your phone number? :)

Dan
-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/lfs/faq.html
Unsubscribe: See the above information page

Reply via email to