Sha256: c39107ee1af2d97e9d20a7b03469c8bc43b7d037b59f947c7fa87dd2da64e4c8

Contents?: true

Size: 439 Bytes

Versions: 8

Compression:

Stored size: 439 Bytes

Contents

module Memo
  class Cli
    module Command
      class Config
        def initialize(
          _,
          os: Memo::OS.new
        )
          @os = os
          @config = Memo::Config.new
          @file = Default::Configfile.to_s
        end

        def call
          tomlfile = ENV["MEMO_CONFIG"] ||
            "#{@config.root}/#{@file}"

          @os.exec "#{@config.editor} #{tomlfile}"
        end
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
ememo-0.2.1 lib/memo/cli/command/config.rb
ememo-0.1.8 lib/memo/cli/command/config.rb
ememo-0.1.7 lib/memo/cli/command/config.rb
ememo-0.1.6 lib/memo/cli/command/config.rb
ememo-0.1.5 lib/memo/cli/command/config.rb
ememo-0.1.4 lib/memo/cli/command/config.rb
ememo-0.1.3 lib/memo/cli/command/config.rb
ememo-0.1.2 lib/memo/cli/command/config.rb