2

I'm trying to run hunspell over my source tree. However when I run this:

find . -name *.html | xargs hunspell -H

The Hunspell editor comes up on the screen, but it won't accept any typed input - all of the input appears at the next command prompt when I type Ctrl+C to exit the hunspell editor. Is there a way I can pipe files to hunspell?

Thanks, Kevin

Kevin Burke
  • 61,194
  • 76
  • 188
  • 305
  • I'm having the same issue, but this seems like a ServerFault question. – Don Branson Apr 03 '12 at 14:53
  • I added: http://serverfault.com/questions/376316/how-can-i-run-hunspell-on-a-list-of-files-with-xargs – Don Branson Apr 03 '12 at 14:58
  • it looks like std input for hunspell is also the pipe, but the pipe is emptied by xargs, so hunspell doesn't get anything. Not sure how to solve it at this point, will give you an answer if I find one, or find it's not doable ;) – drevicko Apr 19 '12 at 07:07

1 Answers1

1

This is based on an answer by nosid here.

xargs -a <(find . -name *.html) hunspell -H

see nosid's answer for an explanation (:

Community
  • 1
  • 1
drevicko
  • 14,382
  • 15
  • 75
  • 97