Sha256: 82940ef7156bd34a4efa34c0caac1c33ca82247f0563bfb521fd0576abafa6b1

Contents?: true

Size: 402 Bytes

Versions: 8

Compression:

Stored size: 402 Bytes

Contents

class Link
  def initialize(src,dst)
    @src = src
    @dst = expand_dst(dst)
  end
  def create
    puts "Link.create"
    puts @dst
    @dst.each do |d|
      puts "src:#{@src}"
      puts "d:#{d} "

      File.symlink(@src, d.to_s)
    end
  end
  def expand_dst(dst)
    ret = Array.new()
    dst.each do |d|
      path = %x[ echo #{d}]
      ret.push(path.strip)
    end
    return ret
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
clenver-0.1.10 lib/clenver/link.rb
clenver-0.1.9 lib/clenver/link.rb
clenver-0.1.8 lib/clenver/link.rb
clenver-0.1.7 lib/clenver/link.rb
clenver-0.1.6 lib/clenver/link.rb
clenver-0.1.5 lib/clenver/link.rb
clenver-0.1.4 lib/clenver/link.rb
clenver-0.1.3 lib/clenver/link.rb