Add auto-complete support for various office file format zip files
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
bash-completion (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: bash-completion
Background:
I am working on a project which involves processing OOXML (Microsoft Office zipped XML fileformat) and ODF (OpenDocument zipped XML fileformat) documents. Often, to debug, or to directly alter files inside of these files, I unzip them somewhere to work on the XML-files inside of these zip-archives.
Problem:
From the command line, unzip doe not autocomplete some of these files because the auto-complete file doesn't know they are valid zip-files.
Missing file extensions:
Presently, bash-completion uses this line for unzip and zipinfo:
complete -f -X '!*.@(zip|
Some of the ODF extensions are already present. I would like to extend this list with all of the more common ODF and OOXML file extensions:
docx
dotx
docm
dotm
pptx
potx
pptm
potm
xlsx
xltx
xlsm
xltm
odt
ott
ods
ots
odp
otp
odc
otc
odg
otg
odf
otf
odm
The above can combined for use in that combine string:
ot[tspgfc]
od[tspgfcm]
dot[xm]
doc[xm]
p[op]tx
p[op]tm
xlt[xm]
xls[xm]
Or even more compact if more than one [] section is possible:
o[dt][tspgfc]
odm
do[tc][xm]
p[op]t[xm]
xl[ts][xm]
Changed in bash-completion (Ubuntu): | |
status: | Confirmed → Fix Released |
Having these file extensions auto-complete is also useful for users who simply want to extract all images from an office file. Both ODF and OOXML store the images used inside of office documents as binary files inside of the office zip-archives.