I have seen papers that take change in Gibbs Energy by just adding a 'eU' term where U is the potential applied. Is there any better way to do this in Quantum Espresso? And is the former way accurate enough?
From the Quantum ESPRESSO website:
There are two different implementations of macroscopic electric fields in pw.x: via an external sawtooth potential (input variable tefield=.true.) and via the modern theory of polarizability (lelfield=.true.). The former is useful for surfaces, especially in conjunction with dipolar corrections (dipfield=.true.): see examples/dipole_example for an example of application. Electric fields via the modern theory of polarization are documented in example 10. The exact meaning of the related variables, for both cases, is explained in the general input documentation.
I don't know if it is what are you looking for, but the tag tefield should help you.