Class: TYUtil::Dir

Inherits:
Object
  • Object
show all
Defined in:
lib/tuya/ci/core/util/dir.rb

Class Method Summary collapse

Class Method Details

.dir_ensure(path) ⇒ Object



3
4
5
6
7
8
9
10
11
12
13
14
# File 'lib/tuya/ci/core/util/dir.rb', line 3

def self.dir_ensure(path)
	dir = FileUtils.pwd

	puts "Original dir is #{FileUtils.pwd}".green

	dir.gsub!(/\/#{path}/, '')

	FileUtils.cd dir

	puts "Current dir is #{FileUtils.pwd}".green

end

.dir_ensure_fastlaneObject



16
17
18
# File 'lib/tuya/ci/core/util/dir.rb', line 16

def self.dir_ensure_fastlane
	dir_ensure 'fastlane'
end