Sha256: 3d24da5e33774bd874edb47084f7256a2a9f425f5f32c73ddfe71cd444036f3d

Contents?: true

Size: 1023 Bytes

Versions: 8

Compression:

Stored size: 1023 Bytes

Contents

# frozen_string_literal: true

require "thor"

require_relative "./list"
require_relative "./set"
require_relative "./unset"

module NeetoDeploy
  class CLI
    module Config
      class Commands < Thor
        desc "list", "List all config vars"
        option :app, type: :string, aliases: "-a", required: true, desc: "App slug" # TODO make this a common static function
        def list
          List.new(options:).run
        end

        desc "set CONFIG_VARS", "Set one or more config vars"
        option :app, type: :string, aliases: "-a", required: true, desc: "App slug" # TODO make this a common static function
        def set(*config_vars)
          Set.new(config_vars, options:).run
        end

        desc "unset CONFIG_VARS", "Unset one or more config vars"
        option :app, type: :string, aliases: "-a", required: true, desc: "App slug" # TODO make this a common static function
        def unset(*config_vars)
          Unset.new(config_vars, options:).run
        end
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
neetodeploy-1.1.2 lib/neeto_deploy/cli/config/commands.rb
neetodeploy-1.1.1 lib/neeto_deploy/cli/config/commands.rb
neetodeploy-1.1.0 lib/neeto_deploy/cli/config/commands.rb
neetodeploy-1.0.10 lib/neeto_deploy/cli/config/commands.rb
neetodeploy-1.0.9 lib/neeto_deploy/cli/config/commands.rb
neetodeploy-1.0.8 lib/neeto_deploy/cli/config/commands.rb
neetodeploy-1.0.7 lib/neeto_deploy/cli/config/commands.rb
neetodeploy-1.0.6 lib/neeto_deploy/cli/config/commands.rb