I have some string
string <- "Shakira - Wolf - 02.Hips don't lie.mp3"
I want only the first part, so the name of the artist. I use regex like this
stri_extract_all_regex(string, "^.*?-")
The output: "Shakira -"
. But I don't want " -"
. How to write regex which allows me to take only the substring which stands before the first " -"
?