Keep it simple ;)

Just define the extract commands as a list, then add the filePath and finally call it.