Sha256: 63df4da30a182dbc54b3754cec14caa0fd3da88b421eee2be05bb6cd1b1a59ed
Contents?: true
Size: 773 Bytes
Versions: 3
Compression:
Stored size: 773 Bytes
Contents
module Souls class Delete < Thor desc "manager_rbs [CLASS_NAME]", "Delete SOULs Manager RBS Template" method_option :mutation, aliases: "--mutation", required: true, desc: "Mutation File Name" def manager_rbs(class_name) file_path = "" singularized_class_name = class_name.underscore.singularize Dir.chdir(Souls.get_mother_path.to_s) do file_dir = "./sig/api/app/graphql/mutations/managers/#{singularized_class_name}_manager" FileUtils.mkdir_p(file_dir) unless Dir.exist?(file_dir) file_path = "#{file_dir}/#{options[:mutation]}.rbs" FileUtils.rm(file_path) puts(Paint % ["Deleted file! : %{white_text}", :yellow, { white_text: [file_path.to_s, :white] }]) end file_path end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
souls-1.8.6 | lib/souls/cli/delete/manager_rbs.rb |
souls-1.8.5 | lib/souls/cli/delete/manager_rbs.rb |
souls-1.8.4 | lib/souls/cli/delete/manager_rbs.rb |