As above,

```sh
if gpg --yes --sign $0
then
    ...
fi
```