updates replacement string
removes bin directory