Improved ability to parse out script blocks from script files