On Oct 28, 2008, at 11:03 , mabshoff wrote:
> On Oct 28, 10:58 am, "Justin C. Walker" <[EMAIL PROTECTED]> wrote:
>> On Oct 28, 2008, at 10:41 , Tim Abbott wrote:
>>
>>> On Oct 28, 1:07 pm, "Justin C. Walker" <[EMAIL PROTECTED]> wrote:
>>>> For example "tar tf foo.spkg" works just fine on Mac OS X (10.5);  
>>>> and
>>>> as Robert noted, you can teach the Finder with the Get-Info trick.
>>
>>> The issue with tar is not on whether tar -xf foo.spkg works, but
>>> whether tar -xf sage_scripts<tab> will complete the remainder of the
>>> filename.
>>
>> I think I'm missing something.  Does 'bash' know about commands and
>> their "file types"?  If I type
>>     tar -xf foo[TAB]
>> and there's a "foo.spkg" in my working directory, I get the
>> completion, unless there are several files with names beginning with
>> "foo" (and then a second [TAB] gives me that list).  Does 'bash' do
>> something special in that case?  Or am I missing your point?
>
> You can use the complete command to associate binaries with certain
> extensions, i.e.
>
> complete -f -X '!*.@(dvi|DVI)?(.@(gz|Z|bz2))' xdvi
>
> from /etc/bash_completion

OK, I have a headache now.  We've gone from "small is beautiful" to  
"small is beside the point".  I suppose it's now just a simple matter  
of adding 'sage' to that list for "tar", right?  Can you make the  
shell add the right switches depending on the extension?

Sheesh.

Justin

--
Justin C. Walker, Curmudgeon at Large
Institute for the Absorption of Federal Funds
-----------
If it weren't for carbon-14, I wouldn't date at all.
-----------



--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to sage-devel@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/sage-devel
URLs: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---

Reply via email to