in reply to Match non-capitalized words at the beginning of each sentence

$/ is (almost) your friend:
local $/; $/ = "."; open FH, "./testfile"; open OH, "> ./outputfile"; while (<FH>) { s/^(\W*)(\w)/$1\u$2/; print OH $_; } close FH; close OH;
And use this as testfile (make your own spelling errors ;):
this is a test sentence. this is another one. we want to test wheter + or not this will make these sentences uppercase. another paratraph. and another sentence. An upercase one. a differetn kind of break. thisone is kind of difficult: www.goof.com.
note that it doesn't handle the domain name very gracefully, as it will not handle any other instances of embedding periods within sentences as non-periods. However, I can't really think of many:

  1. domain names and URLs (and some emails: frank.crist@whatever).
  2. decimal numbers.
  3. dotted lists, such as this one.
  4. elipses (...)
It also doesn't take into account quoted text:
He wondered, "is this in context? possibly."

So, possibly more clever than useful. If the input doesn't follow strict(ish) rules of grammar, you're hosed.