Sha256: 5d0d6b6073324d2fdf968d619dc8bb1a0b2e39f0db3722145cabd80ec01a6895
Contents?: true
Size: 434 Bytes
Versions: 10
Compression:
Stored size: 434 Bytes
Contents
class InitCommand def initialize(options) @options = options end def run path = File.join(Dir.pwd, CARTRCFILE) if File.exist?(path) raise AppError.new, "File #{path} already exists" else File.write(path, file_contents) end end private def file_contents <<~EOS Configuration.setup do |c| c.server = "http://localhost:#{SERVER_DEFAULT_PORT}/" end EOS end end
Version data entries
10 entries across 10 versions & 1 rubygems