Refactor repository, add install script