class RBT::Libtool::RemoveLibtoolFiles
Public Class Methods
from(this_directory)
click to toggle source
new( from_this_directory = return_pwd, run_already = true )
click to toggle source
Public Instance Methods
determine_the_main_directory_automatically()
click to toggle source
determine_which_libtool_files_are_to_be_purged()
click to toggle source
handle_commandline_arguments_with_hyphens()
click to toggle source
#¶ ↑
handle_commandline_arguments_with_hyphens
¶ ↑
#¶ ↑
# File lib/rbt/libtool/remove_libtool_files/remove_libtool_files.rb, line 55 def handle_commandline_arguments_with_hyphens _ = commandline_arguments? if _.any? {|entry| entry.start_with? '--' } selection = _.select {|entry| entry.start_with? '--' } menu(selection) end end
reset()
click to toggle source
#¶ ↑
reset¶ ↑
#¶ ↑
Calls superclass method
RBT::LeanPrototype#reset
# File lib/rbt/libtool/remove_libtool_files/remove_libtool_files.rb, line 43 def reset super() infer_the_namespace # ======================================================================= # # === @all_libtool_files # ======================================================================= # @all_libtool_files = [] # ← Initialize them to an empty Array. end
run()
click to toggle source
set_use_this_directory(i)
click to toggle source
#¶ ↑
set_use_this_directory
¶ ↑
This setter defines which directory we will be using.
#¶ ↑
# File lib/rbt/libtool/remove_libtool_files/remove_libtool_files.rb, line 108 def set_use_this_directory(i) i = i.first if i.is_a? Array i = i.to_s.dup i = return_pwd if i.empty? # <- Use a sane default here. i << '/' unless i.end_with? '/' @internal_hash[:use_this_directory] = i end
show_help()
click to toggle source
#¶ ↑
show_help
(help tag)¶ ↑
#¶ ↑
# File lib/rbt/libtool/remove_libtool_files/remove_libtool_files.rb, line 84 def show_help e e 'Currently this class has no special option.' e e 'The first argument to it should be the target directory. All' e '.la files residing in that directory will be removed then, so' e 'make sure to invoke this class ONLY if you really wish to get' e 'rid of all libtool .la files there.' end
try_to_purge_the_libtool_files()
click to toggle source
#¶ ↑
try_to_purge_the_libtool_files
¶ ↑
#¶ ↑
# File lib/rbt/libtool/remove_libtool_files/remove_libtool_files.rb, line 133 def try_to_purge_the_libtool_files # ======================================================================= # # If we have found at the least one .la file, delete it/them. # ======================================================================= # all_libtool_files = @all_libtool_files unless all_libtool_files.empty? result = powderblue(all_libtool_files.size.to_s)+"#{rev} .la file" result << 's' if all_libtool_files.size > 1 if all_libtool_files.size > 1 result << ' were' else result << ' was' end result << " found at `#{sdir(prefix_to_the_libtool_files?)}`." opne result opne "#{rev}The configure flag #{royalblue('delete_libtool_files')}#{rev}"\ " has been set to true, so" opne "#{rev}these #{slateblue('.la files')}#{rev} will be removed next." remove_these_files(all_libtool_files) end end