3 import findrox
; findrox
.version(1, 9, 6)
4 import sys
, os
, formats
7 from rox
import g
, TRUE
, FALSE
, saving
8 __builtins__
._ = rox
.i18n
.translation(os
.path
.join(rox
.app_dir
, 'Messages'))
10 if len(sys
.argv
) != 2:
11 rox
.info(_("Drag a file or directory onto Archive to archive it. "
12 "Drag an archive onto it to extract."))
15 from box
import ArchiveBox
20 path
= rox
.get_local_path(path
)
22 rox
.croak(_('Sorry, I can only extract/archive local files.'))
23 path
= os
.path
.abspath(path
)
25 # Show the savebox, so at least the user knows something is happening...
27 savebox
= ArchiveBox()
31 if os
.path
.isdir(path
):
32 data
= formats
.DirData(path
)
34 data
= formats
.FileData(path
)
35 savebox
.set_data(data
)