regexp improvements, option to accept hash for scopes in rebase()