Im writing a macro that gets the name of an archive and then rename it to a default name based on the ID of the archive that is inside a table. Im stuck rn because I dont know how to manipulate strings in a macro, I got the whole archive directory, but I would like to have just the name of it, is there a way to do it? I know that something like that can be done using bash script:
grep -o -P '(?<=).*(?=/home)
this command catch whats between ""
and "/home"
. I would like to catch whats between "photos/"
and ""
cause thats where the name of the archive is.