Git管理で、必要なファイルを纏めて管理外にするには、~/.gitignoreを作成して置くのは良いでしょう。
~/.gitignore
puts 'code with syntax'
# Folder view configuration files
.DS_Store
Desktop.ini
# Thumbnail cache files
._*
Thumbs.db
# Files that might appear on external disks
.Spotlight-V100
.Trashes
# Compiled Python files
*.pyc
# Compiled C++ files
*.out
# Application specific files
venv
node_modules
.sass-cache