Skip to content

Instantly share code, notes, and snippets.

@gangelo
Created August 31, 2024 12:31
Show Gist options
  • Save gangelo/65e878e1a1d507812f034a8e3327aef8 to your computer and use it in GitHub Desktop.
Save gangelo/65e878e1a1d507812f034a8e3327aef8 to your computer and use it in GitHub Desktop.
.gitignore file for RoR
# Git Ignore File for Ruby on Rails Development
#
# If you want to use this globally:
# $ touch ~/.gitignore_global
# Copy the contents of this file into ~/.gitignore_global
# $ git config --global core.excludesfile ~/.gitignore_global
# --- Operating System Files ---
# macOS system files
.DS_Store
# Windows system files
Desktop.ini
ehthumbs.db
Thumbs.db
# --- Text Editor/IDE Files ---
# Emacs backup files
*~
# Sublime Text workspace files
*.sublime-workspace
# Vim swap files
*.swo
*.swp
# VSCode settings
.vscode/
.vscode/*
!.vscode/settings.json
# --- Ruby/Rails Specific Files ---
# Bundler config
.bundle
# Ignore sensitive information and credentials
/.env
/config/master.key
# Ignore coverage reports generated by SimpleCov
coverage/
# Log files
/log/*
!/log/.keep
# Temp files
/tmp/*
!/tmp/.keep
/tmp/pids/*
!/tmp/pids/.keep
# Ignore files generated by Solargraph (Ruby language server)
.solargraph.yml
# --- Node.js/Yarn Files ---
# Node modules
node_modules/
# Yarn error log
yarn-error.log
# Asset builds
/app/assets/builds/*
!/app/assets/builds/.keep
# --- Miscellaneous ---
# Ignore any file ending in ~
*~
# Ignore the scratch and snippets files in the root directory of a project
/readme.txt
/scratch.rb
/snippets.rb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment