rewriten sh