to help migrating a code base when enabling esModuleInterop (https://www.typescriptlang.org/tsconfig#esModuleInterop)
# import * as path from "path"
# ⇓
# import path from "path"
git grep -z -l 'import \* as' | xargs -0 perl -pi -e 's/import \* as /import /g'
# only simple module name (e.g. "some-module" but not "./some-file")
git grep -z -l 'import \* as' | xargs -0 perl -pi -e 's/import \* as (\w+) from ("[^\/]+")/import $1 from $2/g'