[tahoe-dev] CLI mkdir inverse?

Peter Secor secorp at allmydata.com
Mon May 4 09:04:25 PDT 2009


Ah, if you are trying to remove an alias, that is a slightly different 
story. In effect, it seems you would be asking to remove the root cap 
from nowhere, which might very well provide an exception. I'm not too 
knowledgeable about this part of the codebase, so I'll let somebody else 
clarify if they can.

Ps

Ben Hyde wrote:
> On May 3, 2009, at 10:48 PM, Peter Secor wrote:
>> Hi Ben,
>>
>>   You can just use the "rm" command to remove a directory, there isn't
>> any difference in Tahoe between removing a mutable file and a  
>> directory.
>>
>> Ps
> 
> That was my first guess; but then I created an alias - letting it
> do the mkdir for me - and I am unable to rm that alias.  Transcript is  
> my
> own grid ...
> 
> bash-3.2$ tahoe ls example:
> bash-3.2$ tahoe rm example:
> Traceback (most recent call last):
>    File "/Users/bhyde/p/allmydata-tahoe-1.4.1/support/bin/tahoe", line  
> 8, in <module>
>      load_entry_point('allmydata-tahoe==1.4.1', 'console_scripts',  
> 'tahoe')()
>    File "/Users/bhyde/p/allmydata-tahoe-1.4.1/src/allmydata/scripts/ 
> runner.py", line 91, in run
>      rc = runner(sys.argv[1:])
>    File "/Users/bhyde/p/allmydata-tahoe-1.4.1/src/allmydata/scripts/ 
> runner.py", line 78, in runner
>      rc = cli.dispatch[command](so)
>    File "/Users/bhyde/p/allmydata-tahoe-1.4.1/src/allmydata/scripts/ 
> cli.py", line 409, in rm
>      rc = tahoe_rm.rm(options)
>    File "/Users/bhyde/p/allmydata-tahoe-1.4.1/src/allmydata/scripts/ 
> tahoe_rm.py", line 25, in rm
>      assert path
> AssertionError
> bash-3.2$
> 
> Reading the code, that assertion fails when the call to get_alias in  
> the rm routine returns an
> empty path; which it does for these top level directories.
> 
> Hm, now I'm thinking this is, in part, because I created the alias
> example via 'tahoe create-alias example'; i.e. let it do the mkdir.  So
> there isn't anything to unlink it from.
> 
>> Ben Hyde wrote:
>>> Is there an inverse for the CLI's mkdir, ala rmdir?
>>> _______________________________________________
>>> tahoe-dev mailing list
>>> tahoe-dev at allmydata.org
>>> http://allmydata.org/cgi-bin/mailman/listinfo/tahoe-dev
>> _______________________________________________
>> tahoe-dev mailing list
>> tahoe-dev at allmydata.org
>> http://allmydata.org/cgi-bin/mailman/listinfo/tahoe-dev
> 
> _______________________________________________
> tahoe-dev mailing list
> tahoe-dev at allmydata.org
> http://allmydata.org/cgi-bin/mailman/listinfo/tahoe-dev


More information about the tahoe-dev mailing list