0
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

時間がかかるコマンドを GNU parallel で 並列実行する

Posted at

LibreOffice の soffice コマンドを使うと Word ファイルから文章を抽出してテキストファイルに変換できるのですが、遅いです。

変換対象の Word ファイルが 100 ファイルぐらいあったので手軽に bash の for f in *.doc *.docx で回したのですが遅すぎたので GNU Parallel を使って並列化しました。

$ parallel -j 5 soffice --headless --convert-to txt {} --outdir ./text ::: *.doc *.docx

-j 5 で 5 ファイルずつ変換されます。

0
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?