Class: Lt
- Inherits:
-
Object
- Object
- Lt
- Defined in:
- lib/linux-tools.rb
Class Method Summary (collapse)
- + (Object) cat
- + (Object) cd
- + (Object) chmod
- + (Object) cp
- + (Object) date
- + (Object) df
- + (Object) du
- + (Object) kill
- + (Object) ls
- + (Object) mkdir
- + (Object) mv
- + (Object) passwd
- + (Object) ps
- + (Object) pwd
- + (Object) rm
- + (Object) rmdir
- + (Object) who
- + (Object) whoami
Class Method Details
+ (Object) cat
12 13 14 15 16 |
# File 'lib/linux-tools.rb', line 12 def self.cat puts "please enter the filename" file = gets system("cat "+file) end |
+ (Object) cd
6 7 8 9 10 |
# File 'lib/linux-tools.rb', line 6 def self.cd puts "this function is currently not operational" dir = gets system("cd "+dir) end |
+ (Object) chmod
18 19 20 21 22 23 |
# File 'lib/linux-tools.rb', line 18 def self.chmod puts "Please enter the mode and the file/directory name(777 /some/directory)" file = gets system("chmod "+mode+" "+file) end |
+ (Object) cp
25 26 27 28 29 |
# File 'lib/linux-tools.rb', line 25 def self.cp puts "please enter the source and destination" file = gets system("cp "+file) end |
+ (Object) date
31 32 |
# File 'lib/linux-tools.rb', line 31 def self.date end |
+ (Object) df
34 35 36 |
# File 'lib/linux-tools.rb', line 34 def self.df end |
+ (Object) du
38 39 40 |
# File 'lib/linux-tools.rb', line 38 def self.du end |
+ (Object) kill
42 43 |
# File 'lib/linux-tools.rb', line 42 def self.kill end |
+ (Object) ls
2 3 4 |
# File 'lib/linux-tools.rb', line 2 def self.ls system("ls") end |
+ (Object) mkdir
45 46 |
# File 'lib/linux-tools.rb', line 45 def self.mkdir end |
+ (Object) mv
48 49 |
# File 'lib/linux-tools.rb', line 48 def self.mv end |
+ (Object) passwd
51 52 |
# File 'lib/linux-tools.rb', line 51 def self.passwd end |
+ (Object) ps
54 55 |
# File 'lib/linux-tools.rb', line 54 def self.ps end |
+ (Object) pwd
57 58 |
# File 'lib/linux-tools.rb', line 57 def self.pwd end |
+ (Object) rm
60 61 |
# File 'lib/linux-tools.rb', line 60 def self.rm end |
+ (Object) rmdir
63 64 |
# File 'lib/linux-tools.rb', line 63 def self.rmdir end |
+ (Object) who
66 67 |
# File 'lib/linux-tools.rb', line 66 def self.who end |
+ (Object) whoami
69 70 |
# File 'lib/linux-tools.rb', line 69 def self.whoami end |