Skip to content

Commit

Permalink
remove puts
Browse files Browse the repository at this point in the history
  • Loading branch information
tanushree04 committed Aug 24, 2023
1 parent 6091535 commit 3714c2e
Showing 1 changed file with 4 additions and 12 deletions.
16 changes: 4 additions & 12 deletions lib/uo_cli.rb
Original file line number Diff line number Diff line change
Expand Up @@ -988,7 +988,6 @@ def self.check_python(python_only: false)
# check versions
m = stdout.match(/^Version: (\S{3,}$)/)
err = true
puts "1HELLO = #{err}"
if m && m.size > 1
if !dep[:version].nil? && dep[:version].to_s == m[1].to_s
puts "...#{dep[:name]} found with specified version #{dep[:version]}"
Expand All @@ -1003,7 +1002,6 @@ def self.check_python(python_only: false)
puts results[:message]
errors << stderr
end
puts "2HELLO = #{errors}"
else
results[:message] = stderr
puts results[:message]
Expand Down Expand Up @@ -1114,14 +1112,10 @@ def self.install_python_dependencies
the_command = ''
if dep[:version].nil?
the_command = "#{pvars[:pip_path]} install #{dep[:name]}"
# # download gmt from github
# elsif dep[:name] == 'geojson-modelica-translator'
# the_command = "#{pvars[:pip_path]} install #{dep[:path]}"
else
the_command = "#{pvars[:pip_path]} install #{dep[:name]}~=#{dep[:version]}"
end


if @opthash.subopts[:verbose]
puts "INSTALL COMMAND: #{the_command}"
end
Expand Down Expand Up @@ -1745,7 +1739,6 @@ def self.install_python_dependencies
end

des_cli_root = "#{res[:pvars][:gmt_path]} build-sys-param"
puts "2HELLO = #{des_cli_root}"
if @opthash.subopts[:sys_param_file]
des_cli_addition = " #{@opthash.subopts[:sys_param_file]}"
if @opthash.subopts[:scenario]
Expand All @@ -1770,12 +1763,11 @@ def self.install_python_dependencies
else
abort("\nCommand must include new system parameter file name, ScenarioFile, & FeatureFile. Please try again")
end
#begin
begin
system(des_cli_root + des_cli_addition)
puts "HELLO = #{des_cli_root + des_cli_addition}"
#rescue FileNotFoundError
# abort("\nMust simulate using 'uo run' before preparing Modelica models.")
#end
rescue FileNotFoundError
abort("\nMust simulate using 'uo run' before preparing Modelica models.")
end
end

if @opthash.command == 'des_create'
Expand Down

0 comments on commit 3714c2e

Please sign in to comment.