The key is to sprinkle them with a liberal amount of kosher salt (but don't go overboard!), then wait patiently for 15 minutes for the salt to draw out the water by osmosis. Then, depending on the amount of water brought forth, either pat dry with a towel or drain using a colander.
This process, known as disgorging vegetables, works well for ratatouille crepes, zucchini-and-egg turnovers, quiche, or any other pastry dish that could turn soggy if vegetables are too moist after cooking. It also helps reduce bitterness and prevent cucumber salads from tasting overly watery. Have you ever tried disgorging vegetables?