add gitignore and save function in classes