Sha256: 04852d21273b698675fe335763e4f12d97f8d5fa7e2b4f6037f2091254c6c2c4

Contents?: true

Size: 832 Bytes

Versions: 11

Compression:

Stored size: 832 Bytes

Contents

# frozen_string_literal: true

require 'toolrack'
require 'teLogger'

require_relative "cli/version"
require_relative 'cli/file_filter'

module ElibMgmt
  module Cli
    class Error < StandardError; end
    # Your code goes here...

    include TR::CondUtils

    def udebug(msg)
      logger.tdebug(:elib, msg) if is_user_debug_on?
    end
    def self.logger
      if @_logger.nil?
        @_logger = TeLogger::Tlogger.new
      end
      @_logger
    end

    def self.is_user_debug_on?
      val = ENV["ELIBMGMT_DEBUG"]
      (not_empty?(val) and val == "true")
    end

    def self.move_to_int_bin(root, file)
      if @_bin.nil?
        @_bin = File.join(root, ".elBin") 
        FileUtils.mkdir_p(@_bin) if not File.exist?(@_bin)
      end

      FileUtils.mv(file, File.join(@_bin, File.basename(file)))
    end

  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
elib_mgmt-cli-0.1.12 lib/elib_mgmt/cli.rb
elib_mgmt-cli-0.1.9 lib/elib_mgmt/cli.rb
elib_mgmt-cli-0.1.8 lib/elib_mgmt/cli.rb
elib_mgmt-cli-0.1.7 lib/elib_mgmt/cli.rb
elib_mgmt-cli-0.1.6 lib/elib_mgmt/cli.rb
elib_mgmt-cli-0.1.5 lib/elib_mgmt/cli.rb
elib_mgmt-cli-0.1.4 lib/elib_mgmt/cli.rb
elib_mgmt-cli-0.1.3 lib/elib_mgmt/cli.rb
elib_mgmt-cli-0.1.2 lib/elib_mgmt/cli.rb
elib_mgmt-cli-0.1.1 lib/elib_mgmt/cli.rb
elib_mgmt-cli-0.1.0 lib/elib_mgmt/cli.rb