@sasjs/core 4.23.4 → 4.24.0
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.
- package/base/mp_copyfolder.sas +8 -5
- package/package.json +1 -1
package/base/mp_copyfolder.sas
CHANGED
|
@@ -16,8 +16,11 @@
|
|
|
16
16
|
|
|
17
17
|
%mp_copyfolder(&rootdir,©dir)
|
|
18
18
|
|
|
19
|
-
@param source Unquoted path to the folder to copy from.
|
|
20
|
-
@param target Unquoted path to the folder to copy to.
|
|
19
|
+
@param [in] source Unquoted path to the folder to copy from.
|
|
20
|
+
@param [out] target Unquoted path to the folder to copy to.
|
|
21
|
+
@param [in] copymax=(MAX) Set to a positive integer to indicate the level of
|
|
22
|
+
subdirectory copy recursion - eg 3, to go `./3/levels/deep`. For unlimited
|
|
23
|
+
recursion, set to MAX.
|
|
21
24
|
|
|
22
25
|
<h4> SAS Macros </h4>
|
|
23
26
|
@li mf_getuniquename.sas
|
|
@@ -31,7 +34,7 @@
|
|
|
31
34
|
|
|
32
35
|
**/
|
|
33
36
|
|
|
34
|
-
%macro mp_copyfolder(source,target);
|
|
37
|
+
%macro mp_copyfolder(source,target,copymax=MAX);
|
|
35
38
|
|
|
36
39
|
%mp_abort(iftrue=(%mf_isdir(&source)=0)
|
|
37
40
|
,mac=&sysmacroname
|
|
@@ -50,7 +53,7 @@
|
|
|
50
53
|
%let tempds=%mf_getuniquename();
|
|
51
54
|
|
|
52
55
|
/* recursive directory listing */
|
|
53
|
-
%mp_dirlist(path=&source,outds=work.&tempds,
|
|
56
|
+
%mp_dirlist(path=&source,outds=work.&tempds,maxdepth=©max)
|
|
54
57
|
|
|
55
58
|
/* create folders and copy content */
|
|
56
59
|
data _null_;
|
|
@@ -78,4 +81,4 @@
|
|
|
78
81
|
proc sql;
|
|
79
82
|
drop table work.&tempds;
|
|
80
83
|
|
|
81
|
-
%mend mp_copyfolder;
|
|
84
|
+
%mend mp_copyfolder;
|
package/package.json
CHANGED