filebydate 0.0.1 → 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/CHANGELOG +2 -1
- data/Rakefile +1 -1
- data/bin/renwdate +3 -1
- data/doc/classes/ConfigTable.html +500 -0
- data/doc/classes/ConfigTable.src/M000002.html +25 -0
- data/doc/classes/ConfigTable.src/M000003.html +18 -0
- data/doc/classes/ConfigTable.src/M000004.html +18 -0
- data/doc/classes/ConfigTable.src/M000005.html +18 -0
- data/doc/classes/ConfigTable.src/M000006.html +18 -0
- data/doc/classes/ConfigTable.src/M000007.html +18 -0
- data/doc/classes/ConfigTable.src/M000008.html +18 -0
- data/doc/classes/ConfigTable.src/M000009.html +18 -0
- data/doc/classes/ConfigTable.src/M000010.html +18 -0
- data/doc/classes/ConfigTable.src/M000011.html +19 -0
- data/doc/classes/ConfigTable.src/M000012.html +21 -0
- data/doc/classes/ConfigTable.src/M000013.html +20 -0
- data/doc/classes/ConfigTable.src/M000014.html +18 -0
- data/doc/classes/ConfigTable.src/M000015.html +25 -0
- data/doc/classes/ConfigTable.src/M000016.html +23 -0
- data/doc/classes/ConfigTable.src/M000017.html +20 -0
- data/doc/classes/ConfigTable.src/M000018.html +20 -0
- data/doc/classes/ConfigTable.src/M000019.html +23 -0
- data/doc/classes/ConfigTable.src/M000020.html +19 -0
- data/doc/classes/ConfigTable.src/M000021.html +18 -0
- data/doc/classes/ConfigTable.src/M000022.html +18 -0
- data/doc/classes/ConfigTable/BoolItem.html +154 -0
- data/doc/classes/ConfigTable/BoolItem.src/M000023.html +18 -0
- data/doc/classes/ConfigTable/BoolItem.src/M000024.html +18 -0
- data/doc/classes/ConfigTable/ExecItem.html +201 -0
- data/doc/classes/ConfigTable/ExecItem.src/M000042.html +20 -0
- data/doc/classes/ConfigTable/ExecItem.src/M000043.html +18 -0
- data/doc/classes/ConfigTable/ExecItem.src/M000044.html +18 -0
- data/doc/classes/ConfigTable/ExecItem.src/M000045.html +18 -0
- data/doc/classes/ConfigTable/ExecItem.src/M000046.html +22 -0
- data/doc/classes/ConfigTable/Item.html +250 -0
- data/doc/classes/ConfigTable/Item.src/M000049.html +22 -0
- data/doc/classes/ConfigTable/Item.src/M000050.html +18 -0
- data/doc/classes/ConfigTable/Item.src/M000051.html +18 -0
- data/doc/classes/ConfigTable/Item.src/M000052.html +18 -0
- data/doc/classes/ConfigTable/Item.src/M000053.html +18 -0
- data/doc/classes/ConfigTable/Item.src/M000054.html +18 -0
- data/doc/classes/ConfigTable/MetaConfigEnvironment.html +325 -0
- data/doc/classes/ConfigTable/MetaConfigEnvironment.src/M000029.html +19 -0
- data/doc/classes/ConfigTable/MetaConfigEnvironment.src/M000030.html +18 -0
- data/doc/classes/ConfigTable/MetaConfigEnvironment.src/M000031.html +18 -0
- data/doc/classes/ConfigTable/MetaConfigEnvironment.src/M000032.html +18 -0
- data/doc/classes/ConfigTable/MetaConfigEnvironment.src/M000033.html +18 -0
- data/doc/classes/ConfigTable/MetaConfigEnvironment.src/M000034.html +18 -0
- data/doc/classes/ConfigTable/MetaConfigEnvironment.src/M000035.html +18 -0
- data/doc/classes/ConfigTable/MetaConfigEnvironment.src/M000036.html +18 -0
- data/doc/classes/ConfigTable/MetaConfigEnvironment.src/M000037.html +18 -0
- data/doc/classes/ConfigTable/MetaConfigEnvironment.src/M000038.html +18 -0
- data/doc/classes/ConfigTable/MetaConfigEnvironment.src/M000039.html +18 -0
- data/doc/classes/ConfigTable/MetaConfigEnvironment.src/M000040.html +19 -0
- data/doc/classes/ConfigTable/MetaConfigEnvironment.src/M000041.html +19 -0
- data/doc/classes/ConfigTable/PackageSelectionItem.html +169 -0
- data/doc/classes/ConfigTable/PackageSelectionItem.src/M000027.html +19 -0
- data/doc/classes/ConfigTable/PackageSelectionItem.src/M000028.html +18 -0
- data/doc/classes/ConfigTable/PathItem.html +139 -0
- data/doc/classes/ConfigTable/PathItem.src/M000026.html +18 -0
- data/doc/classes/ConfigTable/ProgramItem.html +139 -0
- data/doc/classes/ConfigTable/ProgramItem.src/M000025.html +18 -0
- data/doc/classes/ConfigTable/SelectItem.html +156 -0
- data/doc/classes/ConfigTable/SelectItem.src/M000047.html +19 -0
- data/doc/classes/ConfigTable/SelectItem.src/M000048.html +18 -0
- data/doc/classes/Enumerable.html +118 -0
- data/doc/classes/Errno.html +111 -0
- data/doc/classes/Errno/ENOTEMPTY.html +111 -0
- data/doc/classes/File.html +166 -0
- data/doc/classes/File.src/M000183.html +20 -0
- data/doc/classes/File.src/M000184.html +20 -0
- data/doc/classes/File.src/M000185.html +18 -0
- data/doc/classes/FileByDate.html +208 -0
- data/doc/classes/FileByDate.src/M000198.html +31 -0
- data/doc/classes/FileByDate.src/M000199.html +31 -0
- data/doc/classes/FileOperations.html +375 -0
- data/doc/classes/FileOperations.src/M000200.html +31 -0
- data/doc/classes/FileOperations.src/M000201.html +20 -0
- data/doc/classes/FileOperations.src/M000202.html +20 -0
- data/doc/classes/FileOperations.src/M000203.html +24 -0
- data/doc/classes/FileOperations.src/M000204.html +34 -0
- data/doc/classes/FileOperations.src/M000205.html +27 -0
- data/doc/classes/FileOperations.src/M000206.html +21 -0
- data/doc/classes/FileOperations.src/M000207.html +19 -0
- data/doc/classes/FileOperations.src/M000208.html +40 -0
- data/doc/classes/FileOperations.src/M000209.html +19 -0
- data/doc/classes/FileOperations.src/M000210.html +20 -0
- data/doc/classes/FileOperations.src/M000211.html +18 -0
- data/doc/classes/FileOperations.src/M000212.html +18 -0
- data/doc/classes/FileOperations.src/M000213.html +18 -0
- data/doc/classes/FileOperations.src/M000214.html +20 -0
- data/doc/classes/FileOperations.src/M000215.html +20 -0
- data/doc/classes/FilebydateTest.html +348 -0
- data/doc/classes/FilebydateTest.src/M000169.html +28 -0
- data/doc/classes/FilebydateTest.src/M000170.html +19 -0
- data/doc/classes/FilebydateTest.src/M000171.html +20 -0
- data/doc/classes/FilebydateTest.src/M000172.html +21 -0
- data/doc/classes/FilebydateTest.src/M000173.html +22 -0
- data/doc/classes/FilebydateTest.src/M000174.html +24 -0
- data/doc/classes/FilebydateTest.src/M000175.html +20 -0
- data/doc/classes/FilebydateTest.src/M000176.html +28 -0
- data/doc/classes/FilebydateTest.src/M000177.html +19 -0
- data/doc/classes/FilebydateTest.src/M000178.html +20 -0
- data/doc/classes/FilebydateTest.src/M000179.html +21 -0
- data/doc/classes/FilebydateTest.src/M000180.html +22 -0
- data/doc/classes/FilebydateTest.src/M000181.html +24 -0
- data/doc/classes/FilebydateTest.src/M000182.html +20 -0
- data/doc/classes/HookScriptAPI.html +308 -0
- data/doc/classes/HookScriptAPI.src/M000186.html +18 -0
- data/doc/classes/HookScriptAPI.src/M000188.html +18 -0
- data/doc/classes/HookScriptAPI.src/M000189.html +18 -0
- data/doc/classes/HookScriptAPI.src/M000190.html +18 -0
- data/doc/classes/HookScriptAPI.src/M000191.html +18 -0
- data/doc/classes/HookScriptAPI.src/M000192.html +18 -0
- data/doc/classes/HookScriptAPI.src/M000193.html +18 -0
- data/doc/classes/HookScriptAPI.src/M000194.html +18 -0
- data/doc/classes/HookScriptAPI.src/M000195.html +20 -0
- data/doc/classes/HookScriptAPI.src/M000196.html +20 -0
- data/doc/classes/HookScriptAPI.src/M000197.html +20 -0
- data/doc/classes/Installer.html +1148 -0
- data/doc/classes/Installer.src/M000102.html +21 -0
- data/doc/classes/Installer.src/M000103.html +18 -0
- data/doc/classes/Installer.src/M000104.html +17 -0
- data/doc/classes/Installer.src/M000105.html +18 -0
- data/doc/classes/Installer.src/M000106.html +18 -0
- data/doc/classes/Installer.src/M000107.html +18 -0
- data/doc/classes/Installer.src/M000108.html +18 -0
- data/doc/classes/Installer.src/M000109.html +18 -0
- data/doc/classes/Installer.src/M000110.html +23 -0
- data/doc/classes/Installer.src/M000111.html +18 -0
- data/doc/classes/Installer.src/M000114.html +18 -0
- data/doc/classes/Installer.src/M000118.html +18 -0
- data/doc/classes/Installer.src/M000119.html +18 -0
- data/doc/classes/Installer.src/M000120.html +20 -0
- data/doc/classes/Installer.src/M000122.html +18 -0
- data/doc/classes/Installer.src/M000126.html +36 -0
- data/doc/classes/Installer.src/M000127.html +25 -0
- data/doc/classes/Installer.src/M000128.html +24 -0
- data/doc/classes/Installer.src/M000129.html +19 -0
- data/doc/classes/Installer.src/M000130.html +18 -0
- data/doc/classes/Installer.src/M000131.html +18 -0
- data/doc/classes/Installer.src/M000132.html +21 -0
- data/doc/classes/Installer.src/M000133.html +18 -0
- data/doc/classes/Installer.src/M000134.html +20 -0
- data/doc/classes/Installer.src/M000135.html +18 -0
- data/doc/classes/Installer.src/M000136.html +21 -0
- data/doc/classes/Installer.src/M000137.html +18 -0
- data/doc/classes/Installer.src/M000138.html +22 -0
- data/doc/classes/Installer.src/M000139.html +18 -0
- data/doc/classes/Installer.src/M000140.html +23 -0
- data/doc/classes/Installer.src/M000141.html +18 -0
- data/doc/classes/Installer.src/M000142.html +20 -0
- data/doc/classes/Installer.src/M000143.html +19 -0
- data/doc/classes/Installer.src/M000144.html +19 -0
- data/doc/classes/Installer.src/M000145.html +20 -0
- data/doc/classes/Installer.src/M000146.html +30 -0
- data/doc/classes/Installer.src/M000147.html +20 -0
- data/doc/classes/Installer.src/M000153.html +19 -0
- data/doc/classes/Installer.src/M000154.html +20 -0
- data/doc/classes/Installer.src/M000157.html +19 -0
- data/doc/classes/Installer.src/M000161.html +26 -0
- data/doc/classes/Installer.src/M000162.html +25 -0
- data/doc/classes/Installer.src/M000163.html +29 -0
- data/doc/classes/Installer.src/M000164.html +26 -0
- data/doc/classes/Installer/Shebang.html +202 -0
- data/doc/classes/Installer/Shebang.src/M000165.html +23 -0
- data/doc/classes/Installer/Shebang.src/M000166.html +19 -0
- data/doc/classes/Installer/Shebang.src/M000167.html +19 -0
- data/doc/classes/Installer/Shebang.src/M000168.html +18 -0
- data/doc/classes/SetupError.html +111 -0
- data/doc/classes/ToplevelInstaller.html +621 -0
- data/doc/classes/ToplevelInstaller.src/M000055.html +23 -0
- data/doc/classes/ToplevelInstaller.src/M000056.html +18 -0
- data/doc/classes/ToplevelInstaller.src/M000057.html +25 -0
- data/doc/classes/ToplevelInstaller.src/M000058.html +21 -0
- data/doc/classes/ToplevelInstaller.src/M000059.html +18 -0
- data/doc/classes/ToplevelInstaller.src/M000060.html +18 -0
- data/doc/classes/ToplevelInstaller.src/M000061.html +38 -0
- data/doc/classes/ToplevelInstaller.src/M000062.html +18 -0
- data/doc/classes/ToplevelInstaller.src/M000063.html +18 -0
- data/doc/classes/ToplevelInstaller.src/M000064.html +18 -0
- data/doc/classes/ToplevelInstaller.src/M000065.html +18 -0
- data/doc/classes/ToplevelInstaller.src/M000066.html +18 -0
- data/doc/classes/ToplevelInstaller.src/M000067.html +40 -0
- data/doc/classes/ToplevelInstaller.src/M000068.html +18 -0
- data/doc/classes/ToplevelInstaller.src/M000069.html +18 -0
- data/doc/classes/ToplevelInstaller.src/M000070.html +21 -0
- data/doc/classes/ToplevelInstaller.src/M000076.html +40 -0
- data/doc/classes/ToplevelInstaller.src/M000077.html +31 -0
- data/doc/classes/ToplevelInstaller.src/M000078.html +52 -0
- data/doc/classes/ToplevelInstaller.src/M000079.html +19 -0
- data/doc/classes/ToplevelInstaller.src/M000080.html +18 -0
- data/doc/classes/ToplevelInstaller.src/M000081.html +18 -0
- data/doc/classes/ToplevelInstaller.src/M000082.html +18 -0
- data/doc/classes/ToplevelInstaller.src/M000083.html +20 -0
- data/doc/classes/ToplevelInstaller.src/M000084.html +18 -0
- data/doc/classes/ToplevelInstaller.src/M000085.html +18 -0
- data/doc/classes/ToplevelInstallerMulti.html +398 -0
- data/doc/classes/ToplevelInstallerMulti.src/M000086.html +21 -0
- data/doc/classes/ToplevelInstallerMulti.src/M000087.html +21 -0
- data/doc/classes/ToplevelInstallerMulti.src/M000088.html +23 -0
- data/doc/classes/ToplevelInstallerMulti.src/M000089.html +29 -0
- data/doc/classes/ToplevelInstallerMulti.src/M000090.html +22 -0
- data/doc/classes/ToplevelInstallerMulti.src/M000091.html +21 -0
- data/doc/classes/ToplevelInstallerMulti.src/M000092.html +21 -0
- data/doc/classes/ToplevelInstallerMulti.src/M000093.html +20 -0
- data/doc/classes/ToplevelInstallerMulti.src/M000094.html +20 -0
- data/doc/classes/ToplevelInstallerMulti.src/M000095.html +20 -0
- data/doc/classes/ToplevelInstallerMulti.src/M000096.html +21 -0
- data/doc/classes/ToplevelInstallerMulti.src/M000097.html +21 -0
- data/doc/classes/ToplevelInstallerMulti.src/M000098.html +25 -0
- data/doc/classes/ToplevelInstallerMulti.src/M000099.html +18 -0
- data/doc/classes/ToplevelInstallerMulti.src/M000100.html +18 -0
- data/doc/classes/ToplevelInstallerMulti.src/M000101.html +18 -0
- data/doc/created.rid +1 -0
- data/doc/files/lib/filebydate/version_rb.html +101 -0
- data/doc/files/lib/filebydate_rb.html +101 -0
- data/doc/files/pkg/filebydate-0_0_1/lib/filebydate/version_rb.html +101 -0
- data/doc/files/pkg/filebydate-0_0_1/lib/filebydate_rb.html +101 -0
- data/doc/files/pkg/filebydate-0_0_1/test/filebydate_test_rb.html +109 -0
- data/doc/files/pkg/filebydate-0_0_1/test/test_helper_rb.html +108 -0
- data/doc/files/setup_rb.html +148 -0
- data/doc/files/setup_rb.src/M000001.html +18 -0
- data/doc/files/test/filebydate_test_rb.html +109 -0
- data/doc/files/test/test_helper_rb.html +108 -0
- data/doc/fr_class_index.html +48 -0
- data/doc/fr_file_index.html +35 -0
- data/doc/fr_method_index.html +241 -0
- data/doc/index.html +24 -0
- data/doc/rdoc-style.css +208 -0
- data/lib/filebydate/version.rb +1 -1
- data/test/filebydate_test.rb +3 -7
- data/test/renwdate_test +18 -0
- metadata +264 -4
@@ -0,0 +1,31 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>mkdir_p (FileOperations)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File setup.rb, line 538</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">mkdir_p</span>(<span class="ruby-identifier">dirname</span>, <span class="ruby-identifier">prefix</span> = <span class="ruby-keyword kw">nil</span>)
|
15
|
+
<span class="ruby-identifier">dirname</span> = <span class="ruby-identifier">prefix</span> <span class="ruby-operator">+</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">expand_path</span>(<span class="ruby-identifier">dirname</span>) <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">prefix</span>
|
16
|
+
<span class="ruby-identifier">$stderr</span>.<span class="ruby-identifier">puts</span> <span class="ruby-node">"mkdir -p #{dirname}"</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">verbose?</span>
|
17
|
+
<span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">no_harm?</span>
|
18
|
+
|
19
|
+
<span class="ruby-comment cmt"># Does not check '/', it's too abnormal.</span>
|
20
|
+
<span class="ruby-identifier">dirs</span> = <span class="ruby-constant">File</span>.<span class="ruby-identifier">expand_path</span>(<span class="ruby-identifier">dirname</span>).<span class="ruby-identifier">split</span>(<span class="ruby-regexp re">%r<(?=/)></span>)
|
21
|
+
<span class="ruby-keyword kw">if</span> <span class="ruby-regexp re">/\A[a-z]:\z/i</span> <span class="ruby-operator">=~</span> <span class="ruby-identifier">dirs</span>[<span class="ruby-value">0</span>]
|
22
|
+
<span class="ruby-identifier">disk</span> = <span class="ruby-identifier">dirs</span>.<span class="ruby-identifier">shift</span>
|
23
|
+
<span class="ruby-identifier">dirs</span>[<span class="ruby-value">0</span>] = <span class="ruby-identifier">disk</span> <span class="ruby-operator">+</span> <span class="ruby-identifier">dirs</span>[<span class="ruby-value">0</span>]
|
24
|
+
<span class="ruby-keyword kw">end</span>
|
25
|
+
<span class="ruby-identifier">dirs</span>.<span class="ruby-identifier">each_index</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">idx</span><span class="ruby-operator">|</span>
|
26
|
+
<span class="ruby-identifier">path</span> = <span class="ruby-identifier">dirs</span>[<span class="ruby-value">0</span><span class="ruby-operator">..</span><span class="ruby-identifier">idx</span>].<span class="ruby-identifier">join</span>(<span class="ruby-value str">''</span>)
|
27
|
+
<span class="ruby-constant">Dir</span>.<span class="ruby-identifier">mkdir</span> <span class="ruby-identifier">path</span> <span class="ruby-keyword kw">unless</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">dir?</span>(<span class="ruby-identifier">path</span>)
|
28
|
+
<span class="ruby-keyword kw">end</span>
|
29
|
+
<span class="ruby-keyword kw">end</span></pre>
|
30
|
+
</body>
|
31
|
+
</html>
|
@@ -0,0 +1,20 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>rm_f (FileOperations)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File setup.rb, line 555</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">rm_f</span>(<span class="ruby-identifier">path</span>)
|
15
|
+
<span class="ruby-identifier">$stderr</span>.<span class="ruby-identifier">puts</span> <span class="ruby-node">"rm -f #{path}"</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">verbose?</span>
|
16
|
+
<span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">no_harm?</span>
|
17
|
+
<span class="ruby-identifier">force_remove_file</span> <span class="ruby-identifier">path</span>
|
18
|
+
<span class="ruby-keyword kw">end</span></pre>
|
19
|
+
</body>
|
20
|
+
</html>
|
@@ -0,0 +1,20 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>rm_rf (FileOperations)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File setup.rb, line 561</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">rm_rf</span>(<span class="ruby-identifier">path</span>)
|
15
|
+
<span class="ruby-identifier">$stderr</span>.<span class="ruby-identifier">puts</span> <span class="ruby-node">"rm -rf #{path}"</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">verbose?</span>
|
16
|
+
<span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">no_harm?</span>
|
17
|
+
<span class="ruby-identifier">remove_tree</span> <span class="ruby-identifier">path</span>
|
18
|
+
<span class="ruby-keyword kw">end</span></pre>
|
19
|
+
</body>
|
20
|
+
</html>
|
@@ -0,0 +1,24 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>remove_tree (FileOperations)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File setup.rb, line 567</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">remove_tree</span>(<span class="ruby-identifier">path</span>)
|
15
|
+
<span class="ruby-keyword kw">if</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">symlink?</span>(<span class="ruby-identifier">path</span>)
|
16
|
+
<span class="ruby-identifier">remove_file</span> <span class="ruby-identifier">path</span>
|
17
|
+
<span class="ruby-keyword kw">elsif</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">dir?</span>(<span class="ruby-identifier">path</span>)
|
18
|
+
<span class="ruby-identifier">remove_tree0</span> <span class="ruby-identifier">path</span>
|
19
|
+
<span class="ruby-keyword kw">else</span>
|
20
|
+
<span class="ruby-identifier">force_remove_file</span> <span class="ruby-identifier">path</span>
|
21
|
+
<span class="ruby-keyword kw">end</span>
|
22
|
+
<span class="ruby-keyword kw">end</span></pre>
|
23
|
+
</body>
|
24
|
+
</html>
|
@@ -0,0 +1,34 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>remove_tree0 (FileOperations)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File setup.rb, line 577</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">remove_tree0</span>(<span class="ruby-identifier">path</span>)
|
15
|
+
<span class="ruby-constant">Dir</span>.<span class="ruby-identifier">foreach</span>(<span class="ruby-identifier">path</span>) <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">ent</span><span class="ruby-operator">|</span>
|
16
|
+
<span class="ruby-keyword kw">next</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">ent</span> <span class="ruby-operator">==</span> <span class="ruby-value str">'.'</span>
|
17
|
+
<span class="ruby-keyword kw">next</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">ent</span> <span class="ruby-operator">==</span> <span class="ruby-value str">'..'</span>
|
18
|
+
<span class="ruby-identifier">entpath</span> = <span class="ruby-node">"#{path}/#{ent}"</span>
|
19
|
+
<span class="ruby-keyword kw">if</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">symlink?</span>(<span class="ruby-identifier">entpath</span>)
|
20
|
+
<span class="ruby-identifier">remove_file</span> <span class="ruby-identifier">entpath</span>
|
21
|
+
<span class="ruby-keyword kw">elsif</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">dir?</span>(<span class="ruby-identifier">entpath</span>)
|
22
|
+
<span class="ruby-identifier">remove_tree0</span> <span class="ruby-identifier">entpath</span>
|
23
|
+
<span class="ruby-keyword kw">else</span>
|
24
|
+
<span class="ruby-identifier">force_remove_file</span> <span class="ruby-identifier">entpath</span>
|
25
|
+
<span class="ruby-keyword kw">end</span>
|
26
|
+
<span class="ruby-keyword kw">end</span>
|
27
|
+
<span class="ruby-keyword kw">begin</span>
|
28
|
+
<span class="ruby-constant">Dir</span>.<span class="ruby-identifier">rmdir</span> <span class="ruby-identifier">path</span>
|
29
|
+
<span class="ruby-keyword kw">rescue</span> <span class="ruby-constant">Errno</span><span class="ruby-operator">::</span><span class="ruby-constant">ENOTEMPTY</span>
|
30
|
+
<span class="ruby-comment cmt"># directory may not be empty</span>
|
31
|
+
<span class="ruby-keyword kw">end</span>
|
32
|
+
<span class="ruby-keyword kw">end</span></pre>
|
33
|
+
</body>
|
34
|
+
</html>
|
@@ -0,0 +1,27 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>move_file (FileOperations)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File setup.rb, line 597</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">move_file</span>(<span class="ruby-identifier">src</span>, <span class="ruby-identifier">dest</span>)
|
15
|
+
<span class="ruby-identifier">force_remove_file</span> <span class="ruby-identifier">dest</span>
|
16
|
+
<span class="ruby-keyword kw">begin</span>
|
17
|
+
<span class="ruby-constant">File</span>.<span class="ruby-identifier">rename</span> <span class="ruby-identifier">src</span>, <span class="ruby-identifier">dest</span>
|
18
|
+
<span class="ruby-keyword kw">rescue</span>
|
19
|
+
<span class="ruby-constant">File</span>.<span class="ruby-identifier">open</span>(<span class="ruby-identifier">dest</span>, <span class="ruby-value str">'wb'</span>) {<span class="ruby-operator">|</span><span class="ruby-identifier">f</span><span class="ruby-operator">|</span>
|
20
|
+
<span class="ruby-identifier">f</span>.<span class="ruby-identifier">write</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">binread</span>(<span class="ruby-identifier">src</span>)
|
21
|
+
}
|
22
|
+
<span class="ruby-constant">File</span>.<span class="ruby-identifier">chmod</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">stat</span>(<span class="ruby-identifier">src</span>).<span class="ruby-identifier">mode</span>, <span class="ruby-identifier">dest</span>
|
23
|
+
<span class="ruby-constant">File</span>.<span class="ruby-identifier">unlink</span> <span class="ruby-identifier">src</span>
|
24
|
+
<span class="ruby-keyword kw">end</span>
|
25
|
+
<span class="ruby-keyword kw">end</span></pre>
|
26
|
+
</body>
|
27
|
+
</html>
|
@@ -0,0 +1,21 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>force_remove_file (FileOperations)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File setup.rb, line 610</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">force_remove_file</span>(<span class="ruby-identifier">path</span>)
|
15
|
+
<span class="ruby-keyword kw">begin</span>
|
16
|
+
<span class="ruby-identifier">remove_file</span> <span class="ruby-identifier">path</span>
|
17
|
+
<span class="ruby-keyword kw">rescue</span>
|
18
|
+
<span class="ruby-keyword kw">end</span>
|
19
|
+
<span class="ruby-keyword kw">end</span></pre>
|
20
|
+
</body>
|
21
|
+
</html>
|
@@ -0,0 +1,19 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>remove_file (FileOperations)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File setup.rb, line 617</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">remove_file</span>(<span class="ruby-identifier">path</span>)
|
15
|
+
<span class="ruby-constant">File</span>.<span class="ruby-identifier">chmod</span> <span class="ruby-value">0777</span>, <span class="ruby-identifier">path</span>
|
16
|
+
<span class="ruby-constant">File</span>.<span class="ruby-identifier">unlink</span> <span class="ruby-identifier">path</span>
|
17
|
+
<span class="ruby-keyword kw">end</span></pre>
|
18
|
+
</body>
|
19
|
+
</html>
|
@@ -0,0 +1,40 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>install (FileOperations)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File setup.rb, line 622</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">install</span>(<span class="ruby-identifier">from</span>, <span class="ruby-identifier">dest</span>, <span class="ruby-identifier">mode</span>, <span class="ruby-identifier">prefix</span> = <span class="ruby-keyword kw">nil</span>)
|
15
|
+
<span class="ruby-identifier">$stderr</span>.<span class="ruby-identifier">puts</span> <span class="ruby-node">"install #{from} #{dest}"</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">verbose?</span>
|
16
|
+
<span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">no_harm?</span>
|
17
|
+
|
18
|
+
<span class="ruby-identifier">realdest</span> = <span class="ruby-identifier">prefix</span> <span class="ruby-value">? </span><span class="ruby-identifier">prefix</span> <span class="ruby-operator">+</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">expand_path</span>(<span class="ruby-identifier">dest</span>) <span class="ruby-operator">:</span> <span class="ruby-identifier">dest</span>
|
19
|
+
<span class="ruby-identifier">realdest</span> = <span class="ruby-constant">File</span>.<span class="ruby-identifier">join</span>(<span class="ruby-identifier">realdest</span>, <span class="ruby-constant">File</span>.<span class="ruby-identifier">basename</span>(<span class="ruby-identifier">from</span>)) <span class="ruby-keyword kw">if</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">dir?</span>(<span class="ruby-identifier">realdest</span>)
|
20
|
+
<span class="ruby-identifier">str</span> = <span class="ruby-constant">File</span>.<span class="ruby-identifier">binread</span>(<span class="ruby-identifier">from</span>)
|
21
|
+
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">diff?</span>(<span class="ruby-identifier">str</span>, <span class="ruby-identifier">realdest</span>)
|
22
|
+
<span class="ruby-identifier">verbose_off</span> {
|
23
|
+
<span class="ruby-identifier">rm_f</span> <span class="ruby-identifier">realdest</span> <span class="ruby-keyword kw">if</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">exist?</span>(<span class="ruby-identifier">realdest</span>)
|
24
|
+
}
|
25
|
+
<span class="ruby-constant">File</span>.<span class="ruby-identifier">open</span>(<span class="ruby-identifier">realdest</span>, <span class="ruby-value str">'wb'</span>) {<span class="ruby-operator">|</span><span class="ruby-identifier">f</span><span class="ruby-operator">|</span>
|
26
|
+
<span class="ruby-identifier">f</span>.<span class="ruby-identifier">write</span> <span class="ruby-identifier">str</span>
|
27
|
+
}
|
28
|
+
<span class="ruby-constant">File</span>.<span class="ruby-identifier">chmod</span> <span class="ruby-identifier">mode</span>, <span class="ruby-identifier">realdest</span>
|
29
|
+
|
30
|
+
<span class="ruby-constant">File</span>.<span class="ruby-identifier">open</span>(<span class="ruby-node">"#{objdir_root()}/InstalledFiles"</span>, <span class="ruby-value str">'a'</span>) {<span class="ruby-operator">|</span><span class="ruby-identifier">f</span><span class="ruby-operator">|</span>
|
31
|
+
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">prefix</span>
|
32
|
+
<span class="ruby-identifier">f</span>.<span class="ruby-identifier">puts</span> <span class="ruby-identifier">realdest</span>.<span class="ruby-identifier">sub</span>(<span class="ruby-identifier">prefix</span>, <span class="ruby-value str">''</span>)
|
33
|
+
<span class="ruby-keyword kw">else</span>
|
34
|
+
<span class="ruby-identifier">f</span>.<span class="ruby-identifier">puts</span> <span class="ruby-identifier">realdest</span>
|
35
|
+
<span class="ruby-keyword kw">end</span>
|
36
|
+
}
|
37
|
+
<span class="ruby-keyword kw">end</span>
|
38
|
+
<span class="ruby-keyword kw">end</span></pre>
|
39
|
+
</body>
|
40
|
+
</html>
|
@@ -0,0 +1,19 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>diff? (FileOperations)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File setup.rb, line 648</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">diff?</span>(<span class="ruby-identifier">new_content</span>, <span class="ruby-identifier">path</span>)
|
15
|
+
<span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">true</span> <span class="ruby-keyword kw">unless</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">exist?</span>(<span class="ruby-identifier">path</span>)
|
16
|
+
<span class="ruby-identifier">new_content</span> <span class="ruby-operator">!=</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">binread</span>(<span class="ruby-identifier">path</span>)
|
17
|
+
<span class="ruby-keyword kw">end</span></pre>
|
18
|
+
</body>
|
19
|
+
</html>
|
@@ -0,0 +1,20 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>command (FileOperations)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File setup.rb, line 653</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">command</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>)
|
15
|
+
<span class="ruby-identifier">$stderr</span>.<span class="ruby-identifier">puts</span> <span class="ruby-identifier">args</span>.<span class="ruby-identifier">join</span>(<span class="ruby-value str">' '</span>) <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">verbose?</span>
|
16
|
+
<span class="ruby-identifier">system</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>) <span class="ruby-keyword kw">or</span> <span class="ruby-identifier">raise</span> <span class="ruby-constant">RuntimeError</span>,
|
17
|
+
<span class="ruby-node">"system(#{args.map{|a| a.inspect }.join(' ')}) failed"</span>
|
18
|
+
<span class="ruby-keyword kw">end</span></pre>
|
19
|
+
</body>
|
20
|
+
</html>
|
@@ -0,0 +1,18 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>ruby (FileOperations)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File setup.rb, line 659</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">ruby</span>(<span class="ruby-operator">*</span><span class="ruby-identifier">args</span>)
|
15
|
+
<span class="ruby-identifier">command</span> <span class="ruby-identifier">config</span>(<span class="ruby-value str">'rubyprog'</span>), <span class="ruby-operator">*</span><span class="ruby-identifier">args</span>
|
16
|
+
<span class="ruby-keyword kw">end</span></pre>
|
17
|
+
</body>
|
18
|
+
</html>
|
@@ -0,0 +1,18 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>make (FileOperations)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File setup.rb, line 663</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">make</span>(<span class="ruby-identifier">task</span> = <span class="ruby-keyword kw">nil</span>)
|
15
|
+
<span class="ruby-identifier">command</span>(<span class="ruby-operator">*</span>[<span class="ruby-identifier">config</span>(<span class="ruby-value str">'makeprog'</span>), <span class="ruby-identifier">task</span>].<span class="ruby-identifier">compact</span>)
|
16
|
+
<span class="ruby-keyword kw">end</span></pre>
|
17
|
+
</body>
|
18
|
+
</html>
|
@@ -0,0 +1,18 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>extdir? (FileOperations)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File setup.rb, line 667</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">extdir?</span>(<span class="ruby-identifier">dir</span>)
|
15
|
+
<span class="ruby-constant">File</span>.<span class="ruby-identifier">exist?</span>(<span class="ruby-node">"#{dir}/MANIFEST"</span>) <span class="ruby-keyword kw">or</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">exist?</span>(<span class="ruby-node">"#{dir}/extconf.rb"</span>)
|
16
|
+
<span class="ruby-keyword kw">end</span></pre>
|
17
|
+
</body>
|
18
|
+
</html>
|
@@ -0,0 +1,20 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>files_of (FileOperations)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File setup.rb, line 671</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">files_of</span>(<span class="ruby-identifier">dir</span>)
|
15
|
+
<span class="ruby-constant">Dir</span>.<span class="ruby-identifier">open</span>(<span class="ruby-identifier">dir</span>) {<span class="ruby-operator">|</span><span class="ruby-identifier">d</span><span class="ruby-operator">|</span>
|
16
|
+
<span class="ruby-keyword kw">return</span> <span class="ruby-identifier">d</span>.<span class="ruby-identifier">select</span> {<span class="ruby-operator">|</span><span class="ruby-identifier">ent</span><span class="ruby-operator">|</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">file?</span>(<span class="ruby-node">"#{dir}/#{ent}"</span>) }
|
17
|
+
}
|
18
|
+
<span class="ruby-keyword kw">end</span></pre>
|
19
|
+
</body>
|
20
|
+
</html>
|
@@ -0,0 +1,20 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>directories_of (FileOperations)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File setup.rb, line 679</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">directories_of</span>(<span class="ruby-identifier">dir</span>)
|
15
|
+
<span class="ruby-constant">Dir</span>.<span class="ruby-identifier">open</span>(<span class="ruby-identifier">dir</span>) {<span class="ruby-operator">|</span><span class="ruby-identifier">d</span><span class="ruby-operator">|</span>
|
16
|
+
<span class="ruby-keyword kw">return</span> <span class="ruby-identifier">d</span>.<span class="ruby-identifier">select</span> {<span class="ruby-operator">|</span><span class="ruby-identifier">ent</span><span class="ruby-operator">|</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">dir?</span>(<span class="ruby-node">"#{dir}/#{ent}"</span>) } <span class="ruby-operator">-</span> <span class="ruby-constant">DIR_REJECT</span>
|
17
|
+
}
|
18
|
+
<span class="ruby-keyword kw">end</span></pre>
|
19
|
+
</body>
|
20
|
+
</html>
|
@@ -0,0 +1,348 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
7
|
+
<head>
|
8
|
+
<title>Class: FilebydateTest</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<meta http-equiv="Content-Script-Type" content="text/javascript" />
|
11
|
+
<link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
|
12
|
+
<script type="text/javascript">
|
13
|
+
// <![CDATA[
|
14
|
+
|
15
|
+
function popupCode( url ) {
|
16
|
+
window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
|
17
|
+
}
|
18
|
+
|
19
|
+
function toggleCode( id ) {
|
20
|
+
if ( document.getElementById )
|
21
|
+
elem = document.getElementById( id );
|
22
|
+
else if ( document.all )
|
23
|
+
elem = eval( "document.all." + id );
|
24
|
+
else
|
25
|
+
return false;
|
26
|
+
|
27
|
+
elemStyle = elem.style;
|
28
|
+
|
29
|
+
if ( elemStyle.display != "block" ) {
|
30
|
+
elemStyle.display = "block"
|
31
|
+
} else {
|
32
|
+
elemStyle.display = "none"
|
33
|
+
}
|
34
|
+
|
35
|
+
return true;
|
36
|
+
}
|
37
|
+
|
38
|
+
// Make codeblocks hidden by default
|
39
|
+
document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
|
40
|
+
|
41
|
+
// ]]>
|
42
|
+
</script>
|
43
|
+
|
44
|
+
</head>
|
45
|
+
<body>
|
46
|
+
|
47
|
+
|
48
|
+
|
49
|
+
<div id="classHeader">
|
50
|
+
<table class="header-table">
|
51
|
+
<tr class="top-aligned-row">
|
52
|
+
<td><strong>Class</strong></td>
|
53
|
+
<td class="class-name-in-header">FilebydateTest</td>
|
54
|
+
</tr>
|
55
|
+
<tr class="top-aligned-row">
|
56
|
+
<td><strong>In:</strong></td>
|
57
|
+
<td>
|
58
|
+
<a href="../files/pkg/filebydate-0_0_1/test/filebydate_test_rb.html">
|
59
|
+
pkg/filebydate-0.0.1/test/filebydate_test.rb
|
60
|
+
</a>
|
61
|
+
<br />
|
62
|
+
<a href="../files/test/filebydate_test_rb.html">
|
63
|
+
test/filebydate_test.rb
|
64
|
+
</a>
|
65
|
+
<br />
|
66
|
+
</td>
|
67
|
+
</tr>
|
68
|
+
|
69
|
+
<tr class="top-aligned-row">
|
70
|
+
<td><strong>Parent:</strong></td>
|
71
|
+
<td>
|
72
|
+
Test::Unit::TestCase
|
73
|
+
</td>
|
74
|
+
</tr>
|
75
|
+
</table>
|
76
|
+
</div>
|
77
|
+
<!-- banner header -->
|
78
|
+
|
79
|
+
<div id="bodyContent">
|
80
|
+
|
81
|
+
|
82
|
+
|
83
|
+
<div id="contextContent">
|
84
|
+
|
85
|
+
|
86
|
+
|
87
|
+
</div>
|
88
|
+
|
89
|
+
<div id="method-list">
|
90
|
+
<h3 class="section-bar">Methods</h3>
|
91
|
+
|
92
|
+
<div class="name-list">
|
93
|
+
<a href="#M000169">setup</a>
|
94
|
+
<a href="#M000176">setup</a>
|
95
|
+
<a href="#M000180">test_bin_script_dir</a>
|
96
|
+
<a href="#M000173">test_bin_script_dir</a>
|
97
|
+
<a href="#M000181">test_bin_script_wildcard</a>
|
98
|
+
<a href="#M000174">test_bin_script_wildcard</a>
|
99
|
+
<a href="#M000172">test_mtime_preserved</a>
|
100
|
+
<a href="#M000179">test_mtime_preserved</a>
|
101
|
+
<a href="#M000175">test_no_double_rename</a>
|
102
|
+
<a href="#M000182">test_no_double_rename</a>
|
103
|
+
<a href="#M000170">test_single_file_renamed</a>
|
104
|
+
<a href="#M000177">test_single_file_renamed</a>
|
105
|
+
<a href="#M000178">test_wildcard_files_renamed</a>
|
106
|
+
<a href="#M000171">test_wildcard_files_renamed</a>
|
107
|
+
</div>
|
108
|
+
</div>
|
109
|
+
|
110
|
+
</div>
|
111
|
+
|
112
|
+
|
113
|
+
<!-- if includes -->
|
114
|
+
|
115
|
+
<div id="section">
|
116
|
+
|
117
|
+
|
118
|
+
|
119
|
+
|
120
|
+
|
121
|
+
|
122
|
+
|
123
|
+
|
124
|
+
<!-- if method_list -->
|
125
|
+
<div id="methods">
|
126
|
+
<h3 class="section-bar">Public Instance methods</h3>
|
127
|
+
|
128
|
+
<div id="method-M000169" class="method-detail">
|
129
|
+
<a name="M000169"></a>
|
130
|
+
|
131
|
+
<div class="method-heading">
|
132
|
+
<a href="FilebydateTest.src/M000169.html" target="Code" class="method-signature"
|
133
|
+
onclick="popupCode('FilebydateTest.src/M000169.html');return false;">
|
134
|
+
<span class="method-name">setup</span><span class="method-args">()</span>
|
135
|
+
</a>
|
136
|
+
</div>
|
137
|
+
|
138
|
+
<div class="method-description">
|
139
|
+
<p>
|
140
|
+
We keep some test data in subversion (alternately, we could create it fresh
|
141
|
+
here) and copy it to a temp directory to run the filebydate tests against
|
142
|
+
Test::Unit makes sure this is done before each test, giving us the same
|
143
|
+
clean test data to start with each time
|
144
|
+
</p>
|
145
|
+
</div>
|
146
|
+
</div>
|
147
|
+
|
148
|
+
<div id="method-M000176" class="method-detail">
|
149
|
+
<a name="M000176"></a>
|
150
|
+
|
151
|
+
<div class="method-heading">
|
152
|
+
<a href="FilebydateTest.src/M000176.html" target="Code" class="method-signature"
|
153
|
+
onclick="popupCode('FilebydateTest.src/M000176.html');return false;">
|
154
|
+
<span class="method-name">setup</span><span class="method-args">()</span>
|
155
|
+
</a>
|
156
|
+
</div>
|
157
|
+
|
158
|
+
<div class="method-description">
|
159
|
+
<p>
|
160
|
+
We keep some test data in subversion (alternately, we could create it fresh
|
161
|
+
here) and copy it to a temp directory to run the filebydate tests against
|
162
|
+
Test::Unit makes sure this is done before each test, giving us the same
|
163
|
+
clean test data to start with each time
|
164
|
+
</p>
|
165
|
+
</div>
|
166
|
+
</div>
|
167
|
+
|
168
|
+
<div id="method-M000180" class="method-detail">
|
169
|
+
<a name="M000180"></a>
|
170
|
+
|
171
|
+
<div class="method-heading">
|
172
|
+
<a href="FilebydateTest.src/M000180.html" target="Code" class="method-signature"
|
173
|
+
onclick="popupCode('FilebydateTest.src/M000180.html');return false;">
|
174
|
+
<span class="method-name">test_bin_script_dir</span><span class="method-args">()</span>
|
175
|
+
</a>
|
176
|
+
</div>
|
177
|
+
|
178
|
+
<div class="method-description">
|
179
|
+
</div>
|
180
|
+
</div>
|
181
|
+
|
182
|
+
<div id="method-M000173" class="method-detail">
|
183
|
+
<a name="M000173"></a>
|
184
|
+
|
185
|
+
<div class="method-heading">
|
186
|
+
<a href="FilebydateTest.src/M000173.html" target="Code" class="method-signature"
|
187
|
+
onclick="popupCode('FilebydateTest.src/M000173.html');return false;">
|
188
|
+
<span class="method-name">test_bin_script_dir</span><span class="method-args">()</span>
|
189
|
+
</a>
|
190
|
+
</div>
|
191
|
+
|
192
|
+
<div class="method-description">
|
193
|
+
</div>
|
194
|
+
</div>
|
195
|
+
|
196
|
+
<div id="method-M000181" class="method-detail">
|
197
|
+
<a name="M000181"></a>
|
198
|
+
|
199
|
+
<div class="method-heading">
|
200
|
+
<a href="FilebydateTest.src/M000181.html" target="Code" class="method-signature"
|
201
|
+
onclick="popupCode('FilebydateTest.src/M000181.html');return false;">
|
202
|
+
<span class="method-name">test_bin_script_wildcard</span><span class="method-args">()</span>
|
203
|
+
</a>
|
204
|
+
</div>
|
205
|
+
|
206
|
+
<div class="method-description">
|
207
|
+
</div>
|
208
|
+
</div>
|
209
|
+
|
210
|
+
<div id="method-M000174" class="method-detail">
|
211
|
+
<a name="M000174"></a>
|
212
|
+
|
213
|
+
<div class="method-heading">
|
214
|
+
<a href="FilebydateTest.src/M000174.html" target="Code" class="method-signature"
|
215
|
+
onclick="popupCode('FilebydateTest.src/M000174.html');return false;">
|
216
|
+
<span class="method-name">test_bin_script_wildcard</span><span class="method-args">()</span>
|
217
|
+
</a>
|
218
|
+
</div>
|
219
|
+
|
220
|
+
<div class="method-description">
|
221
|
+
</div>
|
222
|
+
</div>
|
223
|
+
|
224
|
+
<div id="method-M000172" class="method-detail">
|
225
|
+
<a name="M000172"></a>
|
226
|
+
|
227
|
+
<div class="method-heading">
|
228
|
+
<a href="FilebydateTest.src/M000172.html" target="Code" class="method-signature"
|
229
|
+
onclick="popupCode('FilebydateTest.src/M000172.html');return false;">
|
230
|
+
<span class="method-name">test_mtime_preserved</span><span class="method-args">()</span>
|
231
|
+
</a>
|
232
|
+
</div>
|
233
|
+
|
234
|
+
<div class="method-description">
|
235
|
+
</div>
|
236
|
+
</div>
|
237
|
+
|
238
|
+
<div id="method-M000179" class="method-detail">
|
239
|
+
<a name="M000179"></a>
|
240
|
+
|
241
|
+
<div class="method-heading">
|
242
|
+
<a href="FilebydateTest.src/M000179.html" target="Code" class="method-signature"
|
243
|
+
onclick="popupCode('FilebydateTest.src/M000179.html');return false;">
|
244
|
+
<span class="method-name">test_mtime_preserved</span><span class="method-args">()</span>
|
245
|
+
</a>
|
246
|
+
</div>
|
247
|
+
|
248
|
+
<div class="method-description">
|
249
|
+
</div>
|
250
|
+
</div>
|
251
|
+
|
252
|
+
<div id="method-M000175" class="method-detail">
|
253
|
+
<a name="M000175"></a>
|
254
|
+
|
255
|
+
<div class="method-heading">
|
256
|
+
<a href="FilebydateTest.src/M000175.html" target="Code" class="method-signature"
|
257
|
+
onclick="popupCode('FilebydateTest.src/M000175.html');return false;">
|
258
|
+
<span class="method-name">test_no_double_rename</span><span class="method-args">()</span>
|
259
|
+
</a>
|
260
|
+
</div>
|
261
|
+
|
262
|
+
<div class="method-description">
|
263
|
+
</div>
|
264
|
+
</div>
|
265
|
+
|
266
|
+
<div id="method-M000182" class="method-detail">
|
267
|
+
<a name="M000182"></a>
|
268
|
+
|
269
|
+
<div class="method-heading">
|
270
|
+
<a href="FilebydateTest.src/M000182.html" target="Code" class="method-signature"
|
271
|
+
onclick="popupCode('FilebydateTest.src/M000182.html');return false;">
|
272
|
+
<span class="method-name">test_no_double_rename</span><span class="method-args">()</span>
|
273
|
+
</a>
|
274
|
+
</div>
|
275
|
+
|
276
|
+
<div class="method-description">
|
277
|
+
</div>
|
278
|
+
</div>
|
279
|
+
|
280
|
+
<div id="method-M000170" class="method-detail">
|
281
|
+
<a name="M000170"></a>
|
282
|
+
|
283
|
+
<div class="method-heading">
|
284
|
+
<a href="FilebydateTest.src/M000170.html" target="Code" class="method-signature"
|
285
|
+
onclick="popupCode('FilebydateTest.src/M000170.html');return false;">
|
286
|
+
<span class="method-name">test_single_file_renamed</span><span class="method-args">()</span>
|
287
|
+
</a>
|
288
|
+
</div>
|
289
|
+
|
290
|
+
<div class="method-description">
|
291
|
+
</div>
|
292
|
+
</div>
|
293
|
+
|
294
|
+
<div id="method-M000177" class="method-detail">
|
295
|
+
<a name="M000177"></a>
|
296
|
+
|
297
|
+
<div class="method-heading">
|
298
|
+
<a href="FilebydateTest.src/M000177.html" target="Code" class="method-signature"
|
299
|
+
onclick="popupCode('FilebydateTest.src/M000177.html');return false;">
|
300
|
+
<span class="method-name">test_single_file_renamed</span><span class="method-args">()</span>
|
301
|
+
</a>
|
302
|
+
</div>
|
303
|
+
|
304
|
+
<div class="method-description">
|
305
|
+
</div>
|
306
|
+
</div>
|
307
|
+
|
308
|
+
<div id="method-M000178" class="method-detail">
|
309
|
+
<a name="M000178"></a>
|
310
|
+
|
311
|
+
<div class="method-heading">
|
312
|
+
<a href="FilebydateTest.src/M000178.html" target="Code" class="method-signature"
|
313
|
+
onclick="popupCode('FilebydateTest.src/M000178.html');return false;">
|
314
|
+
<span class="method-name">test_wildcard_files_renamed</span><span class="method-args">()</span>
|
315
|
+
</a>
|
316
|
+
</div>
|
317
|
+
|
318
|
+
<div class="method-description">
|
319
|
+
</div>
|
320
|
+
</div>
|
321
|
+
|
322
|
+
<div id="method-M000171" class="method-detail">
|
323
|
+
<a name="M000171"></a>
|
324
|
+
|
325
|
+
<div class="method-heading">
|
326
|
+
<a href="FilebydateTest.src/M000171.html" target="Code" class="method-signature"
|
327
|
+
onclick="popupCode('FilebydateTest.src/M000171.html');return false;">
|
328
|
+
<span class="method-name">test_wildcard_files_renamed</span><span class="method-args">()</span>
|
329
|
+
</a>
|
330
|
+
</div>
|
331
|
+
|
332
|
+
<div class="method-description">
|
333
|
+
</div>
|
334
|
+
</div>
|
335
|
+
|
336
|
+
|
337
|
+
</div>
|
338
|
+
|
339
|
+
|
340
|
+
</div>
|
341
|
+
|
342
|
+
|
343
|
+
<div id="validator-badges">
|
344
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
345
|
+
</div>
|
346
|
+
|
347
|
+
</body>
|
348
|
+
</html>
|