Heat 2 tablespoons of the olive oil in a skillet, add the onion and cook gently for 5 minutes. Add the tomatoes and garlic, sprinkle with flour, salt, and pepper. Stir in half of the parsley or basil and cook over a low flame for 10 to 15 minutes, or until the mixture has become a little dry. Add th