Sha256: 9551c4696b5d84e5f0c3bdca4b359ea937231e8775df1af58a62801a9ed93d53

Contents?: true

Size: 375 Bytes

Versions: 14

Compression:

Stored size: 375 Bytes

Contents

module Astrails
  module Safe
    class Stream

      attr_accessor :config, :backup
      def initialize(config, backup)
        @config, @backup = config, backup
      end

      def expand(path)
        path .
        gsub(/:kind\b/, @backup.kind.to_s) .
        gsub(/:id\b/, @backup.id.to_s) .
        gsub(/:timestamp\b/, @backup.timestamp)
      end

    end
  end
end

Version data entries

14 entries across 14 versions & 3 rubygems

Version Path
astrails-safe-0.1.10 lib/astrails/safe/stream.rb
astrails-safe-0.1.7 lib/astrails/safe/stream.rb
astrails-safe-0.1.8 lib/astrails/safe/stream.rb
astrails-safe-0.1.9 lib/astrails/safe/stream.rb
astrails-safe-0.2.0 lib/astrails/safe/stream.rb
astrails-safe-0.2.1 lib/astrails/safe/stream.rb
astrails-safe-0.2.2 lib/astrails/safe/stream.rb
astrails-safe-0.2.3 lib/astrails/safe/stream.rb
bostonlogic-safe-0.3.0 lib/astrails/safe/stream.rb
astrails-safe-0.2.7 lib/astrails/safe/stream.rb
astrails-safe-0.2.6 lib/astrails/safe/stream.rb
astrails-safe-0.2.5 lib/astrails/safe/stream.rb
webbynode-safe-0.2.5 lib/astrails/safe/stream.rb
astrails-safe-0.2.4 lib/astrails/safe/stream.rb