Class: Zedkit::CLI::Projects
- Defined in:
- lib/zedkit/cli/projects.rb
Class Method Summary collapse
- .create(opts = {}) ⇒ Object
- .delete(opts = {}) ⇒ Object
- .list(opts = {}) ⇒ Object
- .show(opts = {}) ⇒ Object
- .update(opts = {}) ⇒ Object
Methods inherited from Bottom
Class Method Details
.create(opts = {}) ⇒ Object
36 37 38 |
# File 'lib/zedkit/cli/projects.rb', line 36 def create(opts = {}) puts "\n" << Zedkit::CLI.ee(opts[:locale], :general, :not_done) << "\n\n" end |
.delete(opts = {}) ⇒ Object
44 45 46 |
# File 'lib/zedkit/cli/projects.rb', line 44 def delete(opts = {}) puts "\n" << Zedkit::CLI.ee(opts[:locale], :general, :not_done) << "\n\n" end |
.list(opts = {}) ⇒ Object
22 23 24 25 26 27 28 29 30 |
# File 'lib/zedkit/cli/projects.rb', line 22 def list(opts = {}) rs = dashes(122) << "| #{'Zedkit Projects'.ljust(118)} |\n" << dashes(122) \ << "| #{'UUID'.ljust(32)} | #{'Name'.ljust(32)} | #{'Location'.ljust(48)} |\n" << dashes(122) Zedkit::Users::Projects.get(:user_key => opts[:user_key]) do |up| pp = Zedkit::Project.new.set_with_hash up['project'] rs << "| #{pp.uuid.ljust(32)} | #{pp.name.ljust(32)} | #{pp.location.ljust(48)} |\n" end puts rs << dashes(122) end |