I have a folder. In this folder I have a lot of other folders. In folders I have bzip files and non-bzip. How to unarchieve all bzip2 files in same directory where they are ?
Asked
Active
Viewed 186 times
1 Answers
1
If your bzip2 files have the standard bz2 extension, try this:
find some_dir_with_bzip2_files -name *.bz2 -exec bunzip2 {} \;
Full example:
$ tree a a ├── b │ ├── d │ ├── file.four │ └── file.three ├── c │ └── e │ ├── file.seven.bz2 │ └── file.six.bz2 ├── file.one.bz2 └── file.two.bz2 $ find a -name *.bz2 -exec bunzip2 {} \; $ tree a a ├── b │ ├── d │ ├── file.four │ └── file.three ├── c │ └── e │ ├── file.seven │ └── file.six ├── file.one └── file.two

cpk
- 11
- 1