changed unimpaired to use p as option to switch between paste/nopaste
extracted code used for switching between production and spec codes for rails and js assets