add file shell, refactor