File tree Expand file tree Collapse file tree 1 file changed +9
-3
lines changed
Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -33,13 +33,19 @@ def checkedFile(path):
3333proj_dir = os .getenv ("PROJECT_DIR" )
3434print (f"PROJECT_DIR: { proj_dir } " )
3535
36- # verify src/dest dirs
36+ # verify src dirs
3737sources_dir = checkedDir (os .path .join (proj_dir , "JDStatusBarNotification" ))
3838swift_source = checkedFile (os .path .join (sources_dir , "Public/NotificationPresenter.swift" ))
39- spm_mirror_dir_name = "spm_sources"
40- spm_mirror_dir = checkedDir (os .path .join (proj_dir , spm_mirror_dir_name ))
4139
4240# copy to dest dir
41+ spm_mirror_dir_name = "spm_sources"
42+ spm_mirror_dir = os .path .join (proj_dir , spm_mirror_dir_name )
43+
44+ if os .path .isdir (spm_mirror_dir ):
45+ print (f"Deleting existing copies." )
46+ shutil .rmtree (spm_mirror_dir )
47+ os .mkdir (spm_mirror_dir )
48+
4349print (f"Copying sources to: { spm_mirror_dir_name } " )
4450shutil .copytree (sources_dir , spm_mirror_dir , dirs_exist_ok = True )
4551
You can’t perform that action at this time.
0 commit comments