hparra / gulp-rename

Rename files easily
MIT License
692 stars 73 forks source link

Directory and sub-directory files rename #68

Closed brb-elia closed 6 years ago

brb-elia commented 8 years ago

I have this directory structure:

#NAME#
    #NAME#-info.plist
    #NAME#-Prefix.pch
    ...
#NAME#.xcodeproj

and I use this code for renaming all the #NAME# placeholder with the correct value:

var name = "TEST";
gulp.src("platforms/ios/**/*\#NAME\#.*")         
    .pipe(rename(function(path) {
        path.dirname = path.dirname.replace("#NAME#", name);
        path.basename = path.basename.replace("#NAME#", name);
        return path;
    }))    
    .pipe(gulp.dest("platforms/ios/"))        

the gulp task only rename (copy but not delete) the #NAME#.xcodeproj file but not the directory and its files. How can I solve this problem?

yocontra commented 6 years ago

New maintainer here - cleaning up old tickets so I'm going to close this - if you still have this issue let me know and I'll reopen it.