File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed
Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -89,6 +89,13 @@ sidebar_json='{
8989 ]
9090}'
9191
92+ # handle OS-specific cp command
93+ if [ " $( uname) " == " Darwin" ]; then
94+ CP_CMD=" cp -R website/docs/ "
95+ else
96+ CP_CMD=" cp -r website/docs/* "
97+ fi
98+
9299# Iterate over each matched branch
93100for branch in $branches ; do
94101 # Remove the remote branch prefix "remotes/origin/"
@@ -111,7 +118,7 @@ for branch in $branches; do
111118 mkdir -p " $version_dir "
112119
113120 # Copy the website/docs directory to the target directory
114- cp -r " website/docs/ " " $version_dir /" || { echo " Failed to copy for branch: $clean_branch_name " ; continue ; }
121+ $CP_CMD " $version_dir /" || { echo " Failed to copy for branch: $clean_branch_name " ; continue ; }
115122 echo " Copied documentation for branch '$clean_branch_name ' to '$version_dir '"
116123 else
117124 echo " The website/docs directory does not exist in branch '$clean_branch_name ', skipping..."
You can’t perform that action at this time.
0 commit comments