linux-tools 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- data/.document +0 -0
- data/.yardoc/checksums +1 -1
- data/.yardoc/objects/root.dat +0 -0
- data/.yardoc/proxy_types +0 -0
- data/Gemfile +8 -4
- data/Gemfile.lock +47 -9
- data/LICENSE.txt +1 -1
- data/README.rdoc +0 -0
- data/Rakefile +17 -16
- data/VERSION +1 -1
- data/doc/Lt.html +245 -165
- data/doc/_index.html +46 -28
- data/doc/class_list.html +26 -9
- data/doc/css/common.css +0 -0
- data/doc/css/full_list.css +6 -2
- data/doc/css/style.css +65 -55
- data/doc/file.LICENSE.html +41 -41
- data/doc/file.README.html +70 -51
- data/doc/file_list.html +31 -11
- data/doc/frames.html +21 -6
- data/doc/index.html +70 -51
- data/doc/js/app.js +67 -56
- data/doc/js/full_list.js +43 -19
- data/doc/js/jquery.js +4 -16
- data/doc/method_list.html +45 -28
- data/doc/top-level-namespace.html +48 -24
- data/features/linux-tools.feature +9 -0
- data/features/step_definitions/linux-tools_steps.rb +0 -0
- data/features/support/env.rb +13 -0
- data/lib/linux-tools.rb +0 -0
- data/linux-tools.gemspec +37 -48
- data/tests/linux-tools_tests.rb +8 -0
- data/{test/helper.rb → tests/tests_helper.rb} +4 -9
- metadata +144 -110
- data/.buildpath +0 -5
- data/.project +0 -17
- data/coverage/index.html +0 -106
- data/coverage/jquery-1.3.2.min.js +0 -19
- data/coverage/jquery.tablesorter.min.js +0 -15
- data/coverage/lib-linux-tools_rb.html +0 -495
- data/coverage/print.css +0 -12
- data/coverage/rcov.js +0 -42
- data/coverage/screen.css +0 -270
- data/lib/build +0 -3
- data/pkg/linux-tools-0.0.0.gem +0 -0
- data/pkg/linux-tools-0.1.0.gem +0 -0
- data/pkg/lt-0.0.0.gem +0 -0
- data/rdoc/classes/Lt.html +0 -553
- data/rdoc/created.rid +0 -1
- data/rdoc/files/README_rdoc.html +0 -141
- data/rdoc/files/lib/linux-tools_rb.html +0 -101
- data/rdoc/fr_class_index.html +0 -27
- data/rdoc/fr_file_index.html +0 -28
- data/rdoc/fr_method_index.html +0 -44
- data/rdoc/index.html +0 -24
- data/rdoc/rdoc-style.css +0 -208
- data/test/test_linux-tools.rb +0 -7
data/.document
CHANGED
File without changes
|
data/.yardoc/checksums
CHANGED
@@ -1 +1 @@
|
|
1
|
-
lib/linux-tools.rb
|
1
|
+
lib/linux-tools.rb 4290ab2908f784e4c6bb07763c81609320f5dfe3
|
data/.yardoc/objects/root.dat
CHANGED
Binary file
|
data/.yardoc/proxy_types
CHANGED
Binary file
|
data/Gemfile
CHANGED
@@ -6,8 +6,12 @@ source "http://rubygems.org"
|
|
6
6
|
# Add dependencies to develop your gem here.
|
7
7
|
# Include everything needed to run rake, tests, features, etc.
|
8
8
|
group :development do
|
9
|
-
gem "
|
10
|
-
gem "
|
11
|
-
gem "
|
12
|
-
gem "
|
9
|
+
gem "shindo", ">= 0"
|
10
|
+
gem "rdoc", "~> 3.12"
|
11
|
+
gem "cucumber", ">= 0"
|
12
|
+
gem "bundler", ">= 1.0.0"
|
13
|
+
gem "jeweler", "~> 1.8.3"
|
14
|
+
gem "simplecov", ">= 0"
|
15
|
+
gem "reek", "~> 1.2.8"
|
16
|
+
gem "roodi", "~> 2.1.0"
|
13
17
|
end
|
data/Gemfile.lock
CHANGED
@@ -1,20 +1,58 @@
|
|
1
1
|
GEM
|
2
2
|
remote: http://rubygems.org/
|
3
3
|
specs:
|
4
|
+
builder (3.0.0)
|
5
|
+
cucumber (1.2.1)
|
6
|
+
builder (>= 2.1.2)
|
7
|
+
diff-lcs (>= 1.1.3)
|
8
|
+
gherkin (~> 2.11.0)
|
9
|
+
json (>= 1.4.6)
|
10
|
+
diff-lcs (1.1.3)
|
11
|
+
formatador (0.2.3)
|
12
|
+
gherkin (2.11.0)
|
13
|
+
json (>= 1.4.6)
|
4
14
|
git (1.2.5)
|
5
|
-
jeweler (1.
|
6
|
-
bundler (~> 1.0
|
15
|
+
jeweler (1.8.3)
|
16
|
+
bundler (~> 1.0)
|
7
17
|
git (>= 1.2.5)
|
8
18
|
rake
|
9
|
-
|
10
|
-
|
11
|
-
|
19
|
+
rdoc
|
20
|
+
json (1.7.3)
|
21
|
+
multi_json (1.3.6)
|
22
|
+
rake (0.9.2.2)
|
23
|
+
rdoc (3.12)
|
24
|
+
json (~> 1.4)
|
25
|
+
reek (1.2.12)
|
26
|
+
ripper_ruby_parser (~> 0.0.7)
|
27
|
+
ruby2ruby (~> 1.2.5)
|
28
|
+
ruby_parser (~> 2.0)
|
29
|
+
sexp_processor (~> 3.0)
|
30
|
+
ripper_ruby_parser (0.0.8)
|
31
|
+
sexp_processor (~> 3.0)
|
32
|
+
roodi (2.1.0)
|
33
|
+
ruby_parser
|
34
|
+
ruby2ruby (1.2.5)
|
35
|
+
ruby_parser (~> 2.0)
|
36
|
+
sexp_processor (~> 3.0)
|
37
|
+
ruby_parser (2.3.1)
|
38
|
+
sexp_processor (~> 3.0)
|
39
|
+
sexp_processor (3.2.0)
|
40
|
+
shindo (0.3.4)
|
41
|
+
formatador (>= 0.1.1)
|
42
|
+
simplecov (0.6.4)
|
43
|
+
multi_json (~> 1.0)
|
44
|
+
simplecov-html (~> 0.5.3)
|
45
|
+
simplecov-html (0.5.3)
|
12
46
|
|
13
47
|
PLATFORMS
|
14
48
|
ruby
|
15
49
|
|
16
50
|
DEPENDENCIES
|
17
|
-
bundler (
|
18
|
-
|
19
|
-
|
20
|
-
|
51
|
+
bundler (>= 1.0.0)
|
52
|
+
cucumber
|
53
|
+
jeweler (~> 1.8.3)
|
54
|
+
rdoc (~> 3.12)
|
55
|
+
reek (~> 1.2.8)
|
56
|
+
roodi (~> 2.1.0)
|
57
|
+
shindo
|
58
|
+
simplecov
|
data/LICENSE.txt
CHANGED
data/README.rdoc
CHANGED
File without changes
|
data/Rakefile
CHANGED
@@ -1,3 +1,5 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
|
1
3
|
require 'rubygems'
|
2
4
|
require 'bundler'
|
3
5
|
begin
|
@@ -19,30 +21,29 @@ Jeweler::Tasks.new do |gem|
|
|
19
21
|
gem.description = %Q{Common *NIX tools and commands which can be used easily in irb}
|
20
22
|
gem.email = "mrigeshpokhrel@gmail.com"
|
21
23
|
gem.authors = ["Mrigesh Pokhrel"]
|
22
|
-
#
|
23
|
-
# and development dependencies are only needed for development (ie running rake tasks, tests, etc)
|
24
|
-
# gem.add_runtime_dependency 'jabber4r', '> 0.1'
|
25
|
-
# gem.add_development_dependency 'rspec', '> 1.2.3'
|
24
|
+
# dependencies defined in Gemfile
|
26
25
|
end
|
27
26
|
Jeweler::RubygemsDotOrgTasks.new
|
28
27
|
|
29
|
-
require 'rake/
|
30
|
-
Rake::
|
31
|
-
|
32
|
-
|
33
|
-
|
28
|
+
require 'cucumber/rake/task'
|
29
|
+
Cucumber::Rake::Task.new(:features)
|
30
|
+
|
31
|
+
require 'reek/rake/task'
|
32
|
+
Reek::Rake::Task.new do |t|
|
33
|
+
t.fail_on_error = true
|
34
|
+
t.verbose = false
|
35
|
+
t.source_files = 'lib/**/*.rb'
|
34
36
|
end
|
35
37
|
|
36
|
-
require '
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
test.verbose = true
|
38
|
+
require 'roodi'
|
39
|
+
require 'roodi_task'
|
40
|
+
RoodiTask.new do |t|
|
41
|
+
t.verbose = false
|
41
42
|
end
|
42
43
|
|
43
|
-
task :default => :
|
44
|
+
task :default => :tests
|
44
45
|
|
45
|
-
require '
|
46
|
+
require 'rdoc/task'
|
46
47
|
Rake::RDocTask.new do |rdoc|
|
47
48
|
version = File.exist?('VERSION') ? File.read('VERSION') : ""
|
48
49
|
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.2.
|
1
|
+
0.2.1
|
data/doc/Lt.html
CHANGED
@@ -2,47 +2,67 @@
|
|
2
2
|
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
3
3
|
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
4
4
|
<head>
|
5
|
-
<meta http-equiv="Content-Type" content="text/html; charset=
|
6
|
-
<title>
|
7
|
-
|
8
|
-
|
5
|
+
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
6
|
+
<title>
|
7
|
+
Class: Lt
|
8
|
+
|
9
|
+
— Documentation by YARD 0.8.2.1
|
10
|
+
|
11
|
+
</title>
|
12
|
+
|
13
|
+
<link rel="stylesheet" href="css/style.css" type="text/css" media="screen" charset="utf-8" />
|
14
|
+
|
15
|
+
<link rel="stylesheet" href="css/common.css" type="text/css" media="screen" charset="utf-8" />
|
9
16
|
|
10
17
|
<script type="text/javascript" charset="utf-8">
|
18
|
+
hasFrames = window.top.frames.main ? true : false;
|
11
19
|
relpath = '';
|
12
|
-
|
20
|
+
framesUrl = "frames.html#!" + escape(window.location.href);
|
13
21
|
</script>
|
14
|
-
|
15
|
-
|
22
|
+
|
23
|
+
|
24
|
+
<script type="text/javascript" charset="utf-8" src="js/jquery.js"></script>
|
25
|
+
|
26
|
+
<script type="text/javascript" charset="utf-8" src="js/app.js"></script>
|
27
|
+
|
16
28
|
|
17
29
|
</head>
|
18
30
|
<body>
|
19
|
-
<script type="text/javascript" charset="utf-8">
|
20
|
-
if (window.top.frames.main) document.body.className = 'frames';
|
21
|
-
</script>
|
22
|
-
|
23
31
|
<div id="header">
|
24
32
|
<div id="menu">
|
25
33
|
|
26
|
-
<a href="_index.html">Index (L)</a> »
|
34
|
+
<a href="_index.html">Index (L)</a> »
|
27
35
|
|
28
36
|
|
29
37
|
<span class="title">Lt</span>
|
30
38
|
|
31
|
-
|
39
|
+
|
32
40
|
<div class="noframes"><span class="title">(</span><a href="." target="_top">no frames</a><span class="title">)</span></div>
|
33
41
|
</div>
|
34
42
|
|
35
43
|
<div id="search">
|
36
|
-
|
37
|
-
|
38
|
-
|
44
|
+
|
45
|
+
<a class="full_list_link" id="class_list_link"
|
46
|
+
href="class_list.html">
|
47
|
+
Class List
|
48
|
+
</a>
|
49
|
+
|
50
|
+
<a class="full_list_link" id="method_list_link"
|
51
|
+
href="method_list.html">
|
52
|
+
Method List
|
53
|
+
</a>
|
54
|
+
|
55
|
+
<a class="full_list_link" id="file_list_link"
|
56
|
+
href="file_list.html">
|
57
|
+
File List
|
58
|
+
</a>
|
59
|
+
|
39
60
|
</div>
|
40
|
-
|
41
61
|
<div class="clear"></div>
|
42
62
|
</div>
|
43
|
-
|
63
|
+
|
44
64
|
<iframe id="search_frame"></iframe>
|
45
|
-
|
65
|
+
|
46
66
|
<div id="content"><h1>Class: Lt
|
47
67
|
|
48
68
|
|
@@ -82,6 +102,10 @@
|
|
82
102
|
|
83
103
|
|
84
104
|
|
105
|
+
|
106
|
+
|
107
|
+
|
108
|
+
|
85
109
|
|
86
110
|
<h2>
|
87
111
|
Class Method Summary
|
@@ -104,6 +128,7 @@
|
|
104
128
|
|
105
129
|
|
106
130
|
|
131
|
+
|
107
132
|
|
108
133
|
|
109
134
|
<span class="summary_desc"><div class='inline'></div></span>
|
@@ -125,6 +150,7 @@
|
|
125
150
|
|
126
151
|
|
127
152
|
|
153
|
+
|
128
154
|
|
129
155
|
|
130
156
|
<span class="summary_desc"><div class='inline'></div></span>
|
@@ -146,6 +172,7 @@
|
|
146
172
|
|
147
173
|
|
148
174
|
|
175
|
+
|
149
176
|
|
150
177
|
|
151
178
|
<span class="summary_desc"><div class='inline'></div></span>
|
@@ -167,6 +194,7 @@
|
|
167
194
|
|
168
195
|
|
169
196
|
|
197
|
+
|
170
198
|
|
171
199
|
|
172
200
|
<span class="summary_desc"><div class='inline'></div></span>
|
@@ -188,6 +216,7 @@
|
|
188
216
|
|
189
217
|
|
190
218
|
|
219
|
+
|
191
220
|
|
192
221
|
|
193
222
|
<span class="summary_desc"><div class='inline'></div></span>
|
@@ -209,6 +238,7 @@
|
|
209
238
|
|
210
239
|
|
211
240
|
|
241
|
+
|
212
242
|
|
213
243
|
|
214
244
|
<span class="summary_desc"><div class='inline'></div></span>
|
@@ -230,6 +260,7 @@
|
|
230
260
|
|
231
261
|
|
232
262
|
|
263
|
+
|
233
264
|
|
234
265
|
|
235
266
|
<span class="summary_desc"><div class='inline'></div></span>
|
@@ -251,6 +282,7 @@
|
|
251
282
|
|
252
283
|
|
253
284
|
|
285
|
+
|
254
286
|
|
255
287
|
|
256
288
|
<span class="summary_desc"><div class='inline'></div></span>
|
@@ -272,6 +304,7 @@
|
|
272
304
|
|
273
305
|
|
274
306
|
|
307
|
+
|
275
308
|
|
276
309
|
|
277
310
|
<span class="summary_desc"><div class='inline'></div></span>
|
@@ -293,6 +326,7 @@
|
|
293
326
|
|
294
327
|
|
295
328
|
|
329
|
+
|
296
330
|
|
297
331
|
|
298
332
|
<span class="summary_desc"><div class='inline'></div></span>
|
@@ -314,6 +348,7 @@
|
|
314
348
|
|
315
349
|
|
316
350
|
|
351
|
+
|
317
352
|
|
318
353
|
|
319
354
|
<span class="summary_desc"><div class='inline'></div></span>
|
@@ -335,6 +370,7 @@
|
|
335
370
|
|
336
371
|
|
337
372
|
|
373
|
+
|
338
374
|
|
339
375
|
|
340
376
|
<span class="summary_desc"><div class='inline'></div></span>
|
@@ -356,6 +392,7 @@
|
|
356
392
|
|
357
393
|
|
358
394
|
|
395
|
+
|
359
396
|
|
360
397
|
|
361
398
|
<span class="summary_desc"><div class='inline'></div></span>
|
@@ -377,6 +414,7 @@
|
|
377
414
|
|
378
415
|
|
379
416
|
|
417
|
+
|
380
418
|
|
381
419
|
|
382
420
|
<span class="summary_desc"><div class='inline'></div></span>
|
@@ -398,6 +436,7 @@
|
|
398
436
|
|
399
437
|
|
400
438
|
|
439
|
+
|
401
440
|
|
402
441
|
|
403
442
|
<span class="summary_desc"><div class='inline'></div></span>
|
@@ -419,6 +458,7 @@
|
|
419
458
|
|
420
459
|
|
421
460
|
|
461
|
+
|
422
462
|
|
423
463
|
|
424
464
|
<span class="summary_desc"><div class='inline'></div></span>
|
@@ -440,6 +480,7 @@
|
|
440
480
|
|
441
481
|
|
442
482
|
|
483
|
+
|
443
484
|
|
444
485
|
|
445
486
|
<span class="summary_desc"><div class='inline'></div></span>
|
@@ -461,6 +502,7 @@
|
|
461
502
|
|
462
503
|
|
463
504
|
|
505
|
+
|
464
506
|
|
465
507
|
|
466
508
|
<span class="summary_desc"><div class='inline'></div></span>
|
@@ -475,16 +517,18 @@
|
|
475
517
|
|
476
518
|
<div id="class_method_details" class="method_details_list">
|
477
519
|
<h2>Class Method Details</h2>
|
478
|
-
|
520
|
+
|
479
521
|
|
480
522
|
<div class="method_details first">
|
481
|
-
<
|
523
|
+
<h3 class="signature first" id="cat-class_method">
|
482
524
|
|
483
525
|
+ (<tt>Object</tt>) <strong>cat</strong>
|
484
526
|
|
485
527
|
|
486
528
|
|
487
|
-
|
529
|
+
|
530
|
+
|
531
|
+
</h3><table class="source_code">
|
488
532
|
<tr>
|
489
533
|
<td>
|
490
534
|
<pre class="lines">
|
@@ -499,25 +543,26 @@
|
|
499
543
|
<td>
|
500
544
|
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line 12</span>
|
501
545
|
|
502
|
-
<span class='
|
503
|
-
<span class='
|
504
|
-
<span class='
|
505
|
-
<span class='
|
506
|
-
<span class='
|
507
|
-
</pre>
|
546
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_cat'>cat</span>
|
547
|
+
<span class='id identifier rubyid_puts'>puts</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>please enter the filename</span><span class='tstring_end'>"</span></span>
|
548
|
+
<span class='id identifier rubyid_file'>file</span> <span class='op'>=</span> <span class='id identifier rubyid_gets'>gets</span>
|
549
|
+
<span class='id identifier rubyid_system'>system</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>cat </span><span class='tstring_end'>"</span></span><span class='op'>+</span><span class='id identifier rubyid_file'>file</span><span class='rparen'>)</span>
|
550
|
+
<span class='kw'>end</span></pre>
|
508
551
|
</td>
|
509
552
|
</tr>
|
510
553
|
</table>
|
511
554
|
</div>
|
512
555
|
|
513
556
|
<div class="method_details ">
|
514
|
-
<
|
557
|
+
<h3 class="signature " id="cd-class_method">
|
515
558
|
|
516
559
|
+ (<tt>Object</tt>) <strong>cd</strong>
|
517
560
|
|
518
561
|
|
519
562
|
|
520
|
-
|
563
|
+
|
564
|
+
|
565
|
+
</h3><table class="source_code">
|
521
566
|
<tr>
|
522
567
|
<td>
|
523
568
|
<pre class="lines">
|
@@ -532,25 +577,26 @@
|
|
532
577
|
<td>
|
533
578
|
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line 6</span>
|
534
579
|
|
535
|
-
<span class='
|
536
|
-
<span class='
|
537
|
-
<span class='
|
538
|
-
<span class='
|
539
|
-
<span class='
|
540
|
-
</pre>
|
580
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_cd'>cd</span>
|
581
|
+
<span class='id identifier rubyid_puts'>puts</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>this function is currently not operational</span><span class='tstring_end'>"</span></span>
|
582
|
+
<span class='id identifier rubyid_dir'>dir</span> <span class='op'>=</span> <span class='id identifier rubyid_gets'>gets</span>
|
583
|
+
<span class='id identifier rubyid_system'>system</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>cd </span><span class='tstring_end'>"</span></span><span class='op'>+</span><span class='id identifier rubyid_dir'>dir</span><span class='rparen'>)</span>
|
584
|
+
<span class='kw'>end</span></pre>
|
541
585
|
</td>
|
542
586
|
</tr>
|
543
587
|
</table>
|
544
588
|
</div>
|
545
589
|
|
546
590
|
<div class="method_details ">
|
547
|
-
<
|
591
|
+
<h3 class="signature " id="chmod-class_method">
|
548
592
|
|
549
593
|
+ (<tt>Object</tt>) <strong>chmod</strong>
|
550
594
|
|
551
595
|
|
552
596
|
|
553
|
-
|
597
|
+
|
598
|
+
|
599
|
+
</h3><table class="source_code">
|
554
600
|
<tr>
|
555
601
|
<td>
|
556
602
|
<pre class="lines">
|
@@ -566,26 +612,27 @@
|
|
566
612
|
<td>
|
567
613
|
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line 18</span>
|
568
614
|
|
569
|
-
<span class='
|
570
|
-
<span class='
|
571
|
-
<span class='
|
615
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_chmod'>chmod</span>
|
616
|
+
<span class='id identifier rubyid_puts'>puts</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Please enter the mode and the file/directory name(777 /some/directory)</span><span class='tstring_end'>"</span></span>
|
617
|
+
<span class='id identifier rubyid_file'>file</span> <span class='op'>=</span> <span class='id identifier rubyid_gets'>gets</span>
|
572
618
|
|
573
|
-
<span class='
|
574
|
-
<span class='
|
575
|
-
</pre>
|
619
|
+
<span class='id identifier rubyid_system'>system</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>chmod </span><span class='tstring_end'>"</span></span><span class='op'>+</span><span class='id identifier rubyid_mode'>mode</span><span class='op'>+</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'> </span><span class='tstring_end'>"</span></span><span class='op'>+</span><span class='id identifier rubyid_file'>file</span><span class='rparen'>)</span>
|
620
|
+
<span class='kw'>end</span></pre>
|
576
621
|
</td>
|
577
622
|
</tr>
|
578
623
|
</table>
|
579
624
|
</div>
|
580
625
|
|
581
626
|
<div class="method_details ">
|
582
|
-
<
|
627
|
+
<h3 class="signature " id="cp-class_method">
|
583
628
|
|
584
629
|
+ (<tt>Object</tt>) <strong>cp</strong>
|
585
630
|
|
586
631
|
|
587
632
|
|
588
|
-
|
633
|
+
|
634
|
+
|
635
|
+
</h3><table class="source_code">
|
589
636
|
<tr>
|
590
637
|
<td>
|
591
638
|
<pre class="lines">
|
@@ -600,137 +647,156 @@
|
|
600
647
|
<td>
|
601
648
|
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line 25</span>
|
602
649
|
|
603
|
-
<span class='
|
604
|
-
<span class='
|
605
|
-
<span class='
|
606
|
-
<span class='
|
607
|
-
<span class='
|
608
|
-
</pre>
|
650
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_cp'>cp</span>
|
651
|
+
<span class='id identifier rubyid_puts'>puts</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>please enter the source and destination</span><span class='tstring_end'>"</span></span>
|
652
|
+
<span class='id identifier rubyid_file'>file</span> <span class='op'>=</span> <span class='id identifier rubyid_gets'>gets</span>
|
653
|
+
<span class='id identifier rubyid_system'>system</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>cp </span><span class='tstring_end'>"</span></span><span class='op'>+</span><span class='id identifier rubyid_file'>file</span><span class='rparen'>)</span>
|
654
|
+
<span class='kw'>end</span></pre>
|
609
655
|
</td>
|
610
656
|
</tr>
|
611
657
|
</table>
|
612
658
|
</div>
|
613
659
|
|
614
660
|
<div class="method_details ">
|
615
|
-
<
|
661
|
+
<h3 class="signature " id="date-class_method">
|
616
662
|
|
617
663
|
+ (<tt>Object</tt>) <strong>date</strong>
|
618
664
|
|
619
665
|
|
620
666
|
|
621
|
-
|
667
|
+
|
668
|
+
|
669
|
+
</h3><table class="source_code">
|
622
670
|
<tr>
|
623
671
|
<td>
|
624
672
|
<pre class="lines">
|
625
673
|
|
626
674
|
|
627
675
|
31
|
628
|
-
32
|
676
|
+
32
|
677
|
+
33</pre>
|
629
678
|
</td>
|
630
679
|
<td>
|
631
680
|
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line 31</span>
|
632
681
|
|
633
|
-
<span class='
|
634
|
-
<span class='
|
635
|
-
</pre>
|
682
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_date'>date</span>
|
683
|
+
<span class='id identifier rubyid_system'>system</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>date</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span>
|
684
|
+
<span class='kw'>end</span></pre>
|
636
685
|
</td>
|
637
686
|
</tr>
|
638
687
|
</table>
|
639
688
|
</div>
|
640
689
|
|
641
690
|
<div class="method_details ">
|
642
|
-
<
|
691
|
+
<h3 class="signature " id="df-class_method">
|
643
692
|
|
644
693
|
+ (<tt>Object</tt>) <strong>df</strong>
|
645
694
|
|
646
695
|
|
647
696
|
|
648
|
-
|
697
|
+
|
698
|
+
|
699
|
+
</h3><table class="source_code">
|
649
700
|
<tr>
|
650
701
|
<td>
|
651
702
|
<pre class="lines">
|
652
703
|
|
653
704
|
|
654
|
-
34
|
655
705
|
35
|
656
|
-
36
|
706
|
+
36
|
707
|
+
37</pre>
|
657
708
|
</td>
|
658
709
|
<td>
|
659
|
-
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line
|
660
|
-
|
661
|
-
<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='df identifier id'>df</span>
|
710
|
+
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line 35</span>
|
662
711
|
|
663
|
-
<span class='
|
664
|
-
</
|
712
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_df'>df</span>
|
713
|
+
<span class='id identifier rubyid_system'>system</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>df -h</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span>
|
714
|
+
<span class='kw'>end</span></pre>
|
665
715
|
</td>
|
666
716
|
</tr>
|
667
717
|
</table>
|
668
718
|
</div>
|
669
719
|
|
670
720
|
<div class="method_details ">
|
671
|
-
<
|
721
|
+
<h3 class="signature " id="du-class_method">
|
672
722
|
|
673
723
|
+ (<tt>Object</tt>) <strong>du</strong>
|
674
724
|
|
675
725
|
|
676
726
|
|
677
|
-
|
727
|
+
|
728
|
+
|
729
|
+
</h3><table class="source_code">
|
678
730
|
<tr>
|
679
731
|
<td>
|
680
732
|
<pre class="lines">
|
681
733
|
|
682
734
|
|
683
|
-
38
|
684
735
|
39
|
685
|
-
40
|
736
|
+
40
|
737
|
+
41
|
738
|
+
42
|
739
|
+
43</pre>
|
686
740
|
</td>
|
687
741
|
<td>
|
688
|
-
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line
|
689
|
-
|
690
|
-
<span class='def def kw'>def</span> <span class='self self kw'>self</span><span class='dot token'>.</span><span class='du identifier id'>du</span>
|
742
|
+
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line 39</span>
|
691
743
|
|
692
|
-
<span class='
|
693
|
-
</
|
744
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_du'>du</span>
|
745
|
+
<span class='id identifier rubyid_puts'>puts</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Enter the path</span><span class='tstring_end'>"</span></span>
|
746
|
+
<span class='id identifier rubyid_path'>path</span><span class='op'>=</span><span class='id identifier rubyid_gets'>gets</span>
|
747
|
+
<span class='id identifier rubyid_system'>system</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>du -h </span><span class='tstring_end'>"</span></span><span class='op'>+</span><span class='id identifier rubyid_path'>path</span><span class='rparen'>)</span>
|
748
|
+
<span class='kw'>end</span></pre>
|
694
749
|
</td>
|
695
750
|
</tr>
|
696
751
|
</table>
|
697
752
|
</div>
|
698
753
|
|
699
754
|
<div class="method_details ">
|
700
|
-
<
|
755
|
+
<h3 class="signature " id="kill-class_method">
|
701
756
|
|
702
757
|
+ (<tt>Object</tt>) <strong>kill</strong>
|
703
758
|
|
704
759
|
|
705
760
|
|
706
|
-
|
761
|
+
|
762
|
+
|
763
|
+
</h3><table class="source_code">
|
707
764
|
<tr>
|
708
765
|
<td>
|
709
766
|
<pre class="lines">
|
710
767
|
|
711
768
|
|
712
|
-
|
713
|
-
|
769
|
+
45
|
770
|
+
46
|
771
|
+
47
|
772
|
+
48
|
773
|
+
49
|
774
|
+
50</pre>
|
714
775
|
</td>
|
715
776
|
<td>
|
716
|
-
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line
|
777
|
+
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line 45</span>
|
717
778
|
|
718
|
-
<span class='
|
719
|
-
<span class='
|
720
|
-
</
|
779
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_kill'>kill</span>
|
780
|
+
<span class='id identifier rubyid_system'>system</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>ps -e</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span>
|
781
|
+
<span class='id identifier rubyid_puts'>puts</span> <span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>Enter the process id to kill</span><span class='tstring_end'>"</span></span>
|
782
|
+
<span class='id identifier rubyid_pid'>pid</span><span class='op'>=</span><span class='id identifier rubyid_gets'>gets</span>
|
783
|
+
<span class='id identifier rubyid_system'>system</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>kill </span><span class='tstring_end'>"</span></span><span class='op'>+</span><span class='id identifier rubyid_pid'>pid</span><span class='rparen'>)</span>
|
784
|
+
<span class='kw'>end</span></pre>
|
721
785
|
</td>
|
722
786
|
</tr>
|
723
787
|
</table>
|
724
788
|
</div>
|
725
789
|
|
726
790
|
<div class="method_details ">
|
727
|
-
<
|
791
|
+
<h3 class="signature " id="ls-class_method">
|
728
792
|
|
729
793
|
+ (<tt>Object</tt>) <strong>ls</strong>
|
730
794
|
|
731
795
|
|
732
796
|
|
733
|
-
|
797
|
+
|
798
|
+
|
799
|
+
</h3><table class="source_code">
|
734
800
|
<tr>
|
735
801
|
<td>
|
736
802
|
<pre class="lines">
|
@@ -743,253 +809,267 @@
|
|
743
809
|
<td>
|
744
810
|
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line 2</span>
|
745
811
|
|
746
|
-
<span class='
|
747
|
-
<span class='
|
748
|
-
<span class='
|
749
|
-
</pre>
|
812
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_ls'>ls</span>
|
813
|
+
<span class='id identifier rubyid_system'>system</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>ls</span><span class='tstring_end'>"</span></span><span class='rparen'>)</span>
|
814
|
+
<span class='kw'>end</span></pre>
|
750
815
|
</td>
|
751
816
|
</tr>
|
752
817
|
</table>
|
753
818
|
</div>
|
754
819
|
|
755
820
|
<div class="method_details ">
|
756
|
-
<
|
821
|
+
<h3 class="signature " id="mkdir-class_method">
|
757
822
|
|
758
823
|
+ (<tt>Object</tt>) <strong>mkdir</strong>
|
759
824
|
|
760
825
|
|
761
826
|
|
762
|
-
|
827
|
+
|
828
|
+
|
829
|
+
</h3><table class="source_code">
|
763
830
|
<tr>
|
764
831
|
<td>
|
765
832
|
<pre class="lines">
|
766
833
|
|
767
834
|
|
768
|
-
|
769
|
-
|
835
|
+
52
|
836
|
+
53
|
837
|
+
54
|
838
|
+
55
|
839
|
+
56</pre>
|
770
840
|
</td>
|
771
841
|
<td>
|
772
|
-
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line
|
842
|
+
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line 52</span>
|
773
843
|
|
774
|
-
<span class='
|
775
|
-
<span class='
|
776
|
-
</
|
844
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_mkdir'>mkdir</span>
|
845
|
+
<span class='id identifier rubyid_puts'>puts</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>enter the path</span><span class='tstring_end'>"</span></span>
|
846
|
+
<span class='id identifier rubyid_mdir'>mdir</span><span class='op'>=</span><span class='id identifier rubyid_gets'>gets</span>
|
847
|
+
<span class='id identifier rubyid_system'>system</span><span class='lparen'>(</span><span class='tstring'><span class='tstring_beg'>"</span><span class='tstring_content'>mkdir </span><span class='tstring_end'>"</span></span><span class='op'>+</span><span class='id identifier rubyid_mdir'>mdir</span><span class='rparen'>)</span>
|
848
|
+
<span class='kw'>end</span></pre>
|
777
849
|
</td>
|
778
850
|
</tr>
|
779
851
|
</table>
|
780
852
|
</div>
|
781
853
|
|
782
854
|
<div class="method_details ">
|
783
|
-
<
|
855
|
+
<h3 class="signature " id="mv-class_method">
|
784
856
|
|
785
857
|
+ (<tt>Object</tt>) <strong>mv</strong>
|
786
858
|
|
787
859
|
|
788
860
|
|
789
|
-
|
861
|
+
|
862
|
+
|
863
|
+
</h3><table class="source_code">
|
790
864
|
<tr>
|
791
865
|
<td>
|
792
866
|
<pre class="lines">
|
793
867
|
|
794
868
|
|
795
|
-
|
796
|
-
|
869
|
+
58
|
870
|
+
59</pre>
|
797
871
|
</td>
|
798
872
|
<td>
|
799
|
-
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line
|
873
|
+
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line 58</span>
|
800
874
|
|
801
|
-
<span class='
|
802
|
-
<span class='
|
803
|
-
</pre>
|
875
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_mv'>mv</span>
|
876
|
+
<span class='kw'>end</span></pre>
|
804
877
|
</td>
|
805
878
|
</tr>
|
806
879
|
</table>
|
807
880
|
</div>
|
808
881
|
|
809
882
|
<div class="method_details ">
|
810
|
-
<
|
883
|
+
<h3 class="signature " id="passwd-class_method">
|
811
884
|
|
812
885
|
+ (<tt>Object</tt>) <strong>passwd</strong>
|
813
886
|
|
814
887
|
|
815
888
|
|
816
|
-
|
889
|
+
|
890
|
+
|
891
|
+
</h3><table class="source_code">
|
817
892
|
<tr>
|
818
893
|
<td>
|
819
894
|
<pre class="lines">
|
820
895
|
|
821
896
|
|
822
|
-
|
823
|
-
|
897
|
+
61
|
898
|
+
62</pre>
|
824
899
|
</td>
|
825
900
|
<td>
|
826
|
-
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line
|
901
|
+
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line 61</span>
|
827
902
|
|
828
|
-
<span class='
|
829
|
-
<span class='
|
830
|
-
</pre>
|
903
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_passwd'>passwd</span>
|
904
|
+
<span class='kw'>end</span></pre>
|
831
905
|
</td>
|
832
906
|
</tr>
|
833
907
|
</table>
|
834
908
|
</div>
|
835
909
|
|
836
910
|
<div class="method_details ">
|
837
|
-
<
|
911
|
+
<h3 class="signature " id="ps-class_method">
|
838
912
|
|
839
913
|
+ (<tt>Object</tt>) <strong>ps</strong>
|
840
914
|
|
841
915
|
|
842
916
|
|
843
|
-
|
917
|
+
|
918
|
+
|
919
|
+
</h3><table class="source_code">
|
844
920
|
<tr>
|
845
921
|
<td>
|
846
922
|
<pre class="lines">
|
847
923
|
|
848
924
|
|
849
|
-
|
850
|
-
|
925
|
+
64
|
926
|
+
65</pre>
|
851
927
|
</td>
|
852
928
|
<td>
|
853
|
-
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line
|
929
|
+
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line 64</span>
|
854
930
|
|
855
|
-
<span class='
|
856
|
-
<span class='
|
857
|
-
</pre>
|
931
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_ps'>ps</span>
|
932
|
+
<span class='kw'>end</span></pre>
|
858
933
|
</td>
|
859
934
|
</tr>
|
860
935
|
</table>
|
861
936
|
</div>
|
862
937
|
|
863
938
|
<div class="method_details ">
|
864
|
-
<
|
939
|
+
<h3 class="signature " id="pwd-class_method">
|
865
940
|
|
866
941
|
+ (<tt>Object</tt>) <strong>pwd</strong>
|
867
942
|
|
868
943
|
|
869
944
|
|
870
|
-
|
945
|
+
|
946
|
+
|
947
|
+
</h3><table class="source_code">
|
871
948
|
<tr>
|
872
949
|
<td>
|
873
950
|
<pre class="lines">
|
874
951
|
|
875
952
|
|
876
|
-
|
877
|
-
|
953
|
+
67
|
954
|
+
68</pre>
|
878
955
|
</td>
|
879
956
|
<td>
|
880
|
-
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line
|
957
|
+
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line 67</span>
|
881
958
|
|
882
|
-
<span class='
|
883
|
-
<span class='
|
884
|
-
</pre>
|
959
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_pwd'>pwd</span>
|
960
|
+
<span class='kw'>end</span></pre>
|
885
961
|
</td>
|
886
962
|
</tr>
|
887
963
|
</table>
|
888
964
|
</div>
|
889
965
|
|
890
966
|
<div class="method_details ">
|
891
|
-
<
|
967
|
+
<h3 class="signature " id="rm-class_method">
|
892
968
|
|
893
969
|
+ (<tt>Object</tt>) <strong>rm</strong>
|
894
970
|
|
895
971
|
|
896
972
|
|
897
|
-
|
973
|
+
|
974
|
+
|
975
|
+
</h3><table class="source_code">
|
898
976
|
<tr>
|
899
977
|
<td>
|
900
978
|
<pre class="lines">
|
901
979
|
|
902
980
|
|
903
|
-
|
904
|
-
|
981
|
+
70
|
982
|
+
71</pre>
|
905
983
|
</td>
|
906
984
|
<td>
|
907
|
-
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line
|
985
|
+
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line 70</span>
|
908
986
|
|
909
|
-
<span class='
|
910
|
-
<span class='
|
911
|
-
</pre>
|
987
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_rm'>rm</span>
|
988
|
+
<span class='kw'>end</span></pre>
|
912
989
|
</td>
|
913
990
|
</tr>
|
914
991
|
</table>
|
915
992
|
</div>
|
916
993
|
|
917
994
|
<div class="method_details ">
|
918
|
-
<
|
995
|
+
<h3 class="signature " id="rmdir-class_method">
|
919
996
|
|
920
997
|
+ (<tt>Object</tt>) <strong>rmdir</strong>
|
921
998
|
|
922
999
|
|
923
1000
|
|
924
|
-
|
1001
|
+
|
1002
|
+
|
1003
|
+
</h3><table class="source_code">
|
925
1004
|
<tr>
|
926
1005
|
<td>
|
927
1006
|
<pre class="lines">
|
928
1007
|
|
929
1008
|
|
930
|
-
|
931
|
-
|
1009
|
+
73
|
1010
|
+
74</pre>
|
932
1011
|
</td>
|
933
1012
|
<td>
|
934
|
-
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line
|
1013
|
+
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line 73</span>
|
935
1014
|
|
936
|
-
<span class='
|
937
|
-
<span class='
|
938
|
-
</pre>
|
1015
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_rmdir'>rmdir</span>
|
1016
|
+
<span class='kw'>end</span></pre>
|
939
1017
|
</td>
|
940
1018
|
</tr>
|
941
1019
|
</table>
|
942
1020
|
</div>
|
943
1021
|
|
944
1022
|
<div class="method_details ">
|
945
|
-
<
|
1023
|
+
<h3 class="signature " id="who-class_method">
|
946
1024
|
|
947
1025
|
+ (<tt>Object</tt>) <strong>who</strong>
|
948
1026
|
|
949
1027
|
|
950
1028
|
|
951
|
-
|
1029
|
+
|
1030
|
+
|
1031
|
+
</h3><table class="source_code">
|
952
1032
|
<tr>
|
953
1033
|
<td>
|
954
1034
|
<pre class="lines">
|
955
1035
|
|
956
1036
|
|
957
|
-
|
958
|
-
|
1037
|
+
76
|
1038
|
+
77</pre>
|
959
1039
|
</td>
|
960
1040
|
<td>
|
961
|
-
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line
|
1041
|
+
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line 76</span>
|
962
1042
|
|
963
|
-
<span class='
|
964
|
-
<span class='
|
965
|
-
</pre>
|
1043
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_who'>who</span>
|
1044
|
+
<span class='kw'>end</span></pre>
|
966
1045
|
</td>
|
967
1046
|
</tr>
|
968
1047
|
</table>
|
969
1048
|
</div>
|
970
1049
|
|
971
1050
|
<div class="method_details ">
|
972
|
-
<
|
1051
|
+
<h3 class="signature " id="whoami-class_method">
|
973
1052
|
|
974
1053
|
+ (<tt>Object</tt>) <strong>whoami</strong>
|
975
1054
|
|
976
1055
|
|
977
1056
|
|
978
|
-
|
1057
|
+
|
1058
|
+
|
1059
|
+
</h3><table class="source_code">
|
979
1060
|
<tr>
|
980
1061
|
<td>
|
981
1062
|
<pre class="lines">
|
982
1063
|
|
983
1064
|
|
984
|
-
|
985
|
-
|
1065
|
+
79
|
1066
|
+
80</pre>
|
986
1067
|
</td>
|
987
1068
|
<td>
|
988
|
-
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line
|
1069
|
+
<pre class="code"><span class="info file"># File 'lib/linux-tools.rb', line 79</span>
|
989
1070
|
|
990
|
-
<span class='
|
991
|
-
<span class='
|
992
|
-
</pre>
|
1071
|
+
<span class='kw'>def</span> <span class='kw'>self</span><span class='period'>.</span><span class='id identifier rubyid_whoami'>whoami</span>
|
1072
|
+
<span class='kw'>end</span></pre>
|
993
1073
|
</td>
|
994
1074
|
</tr>
|
995
1075
|
</table>
|
@@ -998,11 +1078,11 @@
|
|
998
1078
|
</div>
|
999
1079
|
|
1000
1080
|
</div>
|
1001
|
-
|
1081
|
+
|
1002
1082
|
<div id="footer">
|
1003
|
-
Generated on
|
1083
|
+
Generated on Sat Jun 23 03:07:04 2012 by
|
1004
1084
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
1005
|
-
0.
|
1085
|
+
0.8.2.1 (ruby-1.9.3).
|
1006
1086
|
</div>
|
1007
1087
|
|
1008
1088
|
</body>
|