fork download
  1. #!/bin/bash
  2. s="this_is_my_task() this_is_my____task() ___this_is_my_task() or tHhi_is_my task()"
  3. perl -pe 's{\b[a-z]+(?:_[a-z]+)+\(\)}{$&=~s/_([a-z])/\u$1/gr}ge' <<< "$s"
  4.  
Success #stdin #stdout 0s 5068KB
stdin
Standard input is empty
stdout
thisIsMyTask() this_is_my____task() ___this_is_my_task() or tHhi_is_my task()