lib/fanforce/cli/utils.rb in fanforce-cli-2.0.0.rc4 vs lib/fanforce/cli/utils.rb in fanforce-cli-2.0.0.rc6
- old
+ new
@@ -63,22 +63,22 @@
def find_cli_type(home_dir)
dir_names = home_dir.split('/')
types = {
directory_of_internals: false,
single_internal: false,
- directory_of_apps: false,
- single_app: false
+ directory_of_plugins: false,
+ single_plugin: false
}
- types[:single_app] = true if File.exists?("#{home_dir}/config.json") and File.exists?("#{home_dir}/../.fanforce-app-factory")
- types[:directory_of_apps] = true if File.exists?("#{home_dir}/.fanforce-app-factory")
+ types[:single_plugin] = true if File.exists?("#{home_dir}/config.json") and File.exists?("#{home_dir}/../.fanforce-plugin-factory")
+ types[:directory_of_plugins] = true if File.exists?("#{home_dir}/.fanforce-plugin-factory")
- if [dir_names[-1],dir_names[-2]].include?('Fanforce') && !File.exists?("#{home_dir}/.git") && !File.exists?("#{home_dir}/.fanforce-app-factory")
+ if [dir_names[-1],dir_names[-2]].include?('Fanforce') && !File.exists?("#{home_dir}/.git") && !File.exists?("#{home_dir}/.fanforce-plugin-factory")
types[:directory_of_internals] = true
end
- if [dir_names[-1],dir_names[-2],dir_names[-2]].include?('Fanforce') and File.exists?("#{home_dir}/.git") and !File.exists?("#{home_dir}/../.fanforce-app-factory")
+ if [dir_names[-1],dir_names[-2],dir_names[-3]].include?('Fanforce') and File.exists?("#{home_dir}/.git") and !File.exists?("#{home_dir}/../.fanforce-plugin-factory")
types[:single_internal] = true
end
found_types = types.inject([]) {|found_types, (key,bool)| bool ? found_types << key : found_types }
@@ -96,6 +96,6 @@
class String
def format(*args)
Fanforce::CLI::Utils.fmt(self, *args)
end
-end
\ No newline at end of file
+end