I am looking for a regular expression that would allow me to find and replace all instances of strings ending with random numbers, e.g.:
Replace all instances of '/app/build/js/app.min.js?r=123456789
with '/app/build/js/app.min.js?r=' + newValue
I tried the following (in JavaScript), but it doesn't seem to work:
var before = '/app/build/js/app.min.js?r=/[0-9]/g';
I need this for a gulp task, which looks like the following:
gulp.src(myFile)
.pipe(replace(before, after))
.pipe(gulp.dest(myPath));
Any ideas what I'm doing wrong?