Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Branch: master
Fetching contributors…

Cannot retrieve contributors at this time

executable file 23 lines (17 sloc) 0.505 kB
#!/usr/bin/env ruby
require 'fileutils'
working_dir = File.expand_path(File.dirname(__FILE__))
home_dir = File.expand_path("~")
dot_files = Dir.glob(File.join(working_dir,"*"))
dot_files.each do |filename|
next if filename =~ /activate\.rb$/
sym_link = File.join(home_dir,".#{File.basename(filename)}")
if File.exist? sym_link
if File.symlink? sym_link
FileUtils.rm sym_link
else
FileUtils.mv sym_link, "#{sym_link}.bak"
end
end
FileUtils.ln_s filename,sym_link
end
Jump to Line
Something went wrong with that request. Please try again.