There are two ways you can use a breach:
1. Almost safe: Dig until you breach the cavern, plug the hole immediately. If you have dug out some soil, just wait for underground plants to grow (from spores received from the breach) and then havest them via plant gathering. If you don't have any dug out soil, dig some out while digging downwards. If you don't have any soil, create mud by pouring water on stone (non trivial process to get it right the first time).
2: Slightly riskier: Dig a breach. It's likely to end up in the air, so plug the hole and dig a new tunnel (with at least one drawbridge to close it before removing the last tile) so you can get out into the cavern. Check the wildlife to select a moment when there aren't too many baddied out there. Send an emergency plant gathering party out there (after marking an area near the breach for gathering), close the drawbridge, eat/brew/process the stuff to get seeds. Actually, I'd probably NOT mark an area for plant gathering, but rather manually select each plant to pick. You don't want any Dimple Cups at this stage.
As you see, 2 is an extension of 1, so I'd start with 2 immediately after having performed 1. The decision point comes when it's time to breach the cavern properly: if you've gotten harvesting going from spores, you can delay it until the breach point defenses are satisfactory, if you haven't gotten any seeds, or the hunger is bad, you don't really have much choice...[Well, you COULD start over, but this kind of crisis is something that ought to be possible to sort out].