Computing $\protect \mathcal{L}$-invariants via the Greenberg–Stevens formula