From 3b7ac85ad84a6815b193ed91bf112e99b0a1eec3 Mon Sep 17 00:00:00 2001 From: tiredpixel Date: Mon, 11 Nov 2013 19:48:31 +0000 Subject: [PATCH 1/2] Slashify Ruby files and directories. Perhaps this is a little pedantic, but without the initial / all such matches within the repository get ignored, and without the trailing slash files as well as directories of that name get ignored. e.g. Specifying `tmp` and `test/tmp` without slashes is redundant, as `tmp` already ignores `test/tmp`, as well as every other `tmp` and `tmp/`. --- Ruby.gitignore | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/Ruby.gitignore b/Ruby.gitignore index b20c5ce6..82aa6fac 100644 --- a/Ruby.gitignore +++ b/Ruby.gitignore @@ -1,23 +1,23 @@ -*.gem -*.rbc -.config -coverage -InstalledFiles +/*.gem +/*.rbc +/.config +/coverage/ +/InstalledFiles /pkg/ -/spec/reports -/test/tmp -/test/version_tmp +/spec/reports/ +/test/tmp/ +/test/version_tmp/ /tmp/ ## Documentation cache and generated files: -/.yardoc -/_yardoc +/.yardoc/ +/_yardoc/ /doc/ -/rdoc +/rdoc/ ## Environment normalisation: -/.bundle -/lib/bundler/man +/.bundle/ +/lib/bundler/man/ # for a library or gem, you might want to ignore these files since the code is # intended to run in multiple environments; otherwise, check them in: @@ -26,4 +26,4 @@ InstalledFiles # .ruby-gemset # unless supporting rvm < 1.11.0 or doing something fancy, ignore this: -.rvmrc +/.rvmrc From ca456f73e42b830dbae55f281a7eb0918944ba28 Mon Sep 17 00:00:00 2001 From: tiredpixel Date: Mon, 11 Nov 2013 21:41:11 +0000 Subject: [PATCH 2/2] Unslashify *.gem,*.rbc,.rvmrc . arcresu pointed out that `*.gem`, `*.rbc`, `.rvmrc` might not be at the top level in a repository. Thus, remove leading slashes for these. --- Ruby.gitignore | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Ruby.gitignore b/Ruby.gitignore index 82aa6fac..99e72c12 100644 --- a/Ruby.gitignore +++ b/Ruby.gitignore @@ -1,5 +1,5 @@ -/*.gem -/*.rbc +*.gem +*.rbc /.config /coverage/ /InstalledFiles @@ -26,4 +26,4 @@ # .ruby-gemset # unless supporting rvm < 1.11.0 or doing something fancy, ignore this: -/.rvmrc +.rvmrc