Had to change the way I've implemented the chdir in the install steps since it errors out
This commit is contained in:
		@@ -170,7 +170,7 @@ class Installer
 | 
				
			|||||||
    file_contents = Net::HTTP.get(uri)
 | 
					    file_contents = Net::HTTP.get(uri)
 | 
				
			||||||
    output_file = "discord-#{version}.tar.gz"
 | 
					    output_file = "discord-#{version}.tar.gz"
 | 
				
			||||||
    puts "download_installer: Output file will #{output_file}"
 | 
					    puts "download_installer: Output file will #{output_file}"
 | 
				
			||||||
    $CONFIG[:install_dir].chdir do 
 | 
					    Dir.chdir($CONFIG[:install_dir]) do 
 | 
				
			||||||
      File.open(output_file, 'wb') do |file|
 | 
					      File.open(output_file, 'wb') do |file|
 | 
				
			||||||
        file.write(file_contents)
 | 
					        file.write(file_contents)
 | 
				
			||||||
      end
 | 
					      end
 | 
				
			||||||
@@ -181,7 +181,7 @@ class Installer
 | 
				
			|||||||
  def install
 | 
					  def install
 | 
				
			||||||
    installer_file = "discord-#{self.remote_version}.tar.gz"
 | 
					    installer_file = "discord-#{self.remote_version}.tar.gz"
 | 
				
			||||||
    puts "do_install: Extracting new installer"
 | 
					    puts "do_install: Extracting new installer"
 | 
				
			||||||
    $CONFIG[:install_dir].chdir do 
 | 
					    Dir.chdir($CONFIG[:install_dir]) do 
 | 
				
			||||||
      File.open(installer_file, 'rb') do |file|
 | 
					      File.open(installer_file, 'rb') do |file|
 | 
				
			||||||
        Gem::Package.new("").extract_tar_gz(file, $CONFIG[:install_dir])
 | 
					        Gem::Package.new("").extract_tar_gz(file, $CONFIG[:install_dir])
 | 
				
			||||||
      end
 | 
					      end
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user