From c6a517e100a0aac3cac9bb964a8b7216d865db71 Mon Sep 17 00:00:00 2001 From: Martinos Date: Sat, 13 Mar 2010 12:42:50 -0500 Subject: [PATCH] Correcting listing of dotfiles in home directory --- lib/homesick.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/homesick.rb b/lib/homesick.rb index bc25771..b2e8d51 100644 --- a/lib/homesick.rb +++ b/lib/homesick.rb @@ -42,7 +42,7 @@ class Homesick < Thor desc "link NAME", "Symlinks all dotfiles from the specified castle" def link(home) inside castle_dir(home) do - files = Pathname.glob('.*')[2..-1] # skip . and .., ie the first two + files = Pathname.glob('.*').reject{|a| [".",".."].include?(a.to_s)} files.each do |path| absolute_path = path.expand_path