wfxr / forgit

:zzz: A utility tool powered by fzf for using git interactively.
MIT License
4.32k stars 136 forks source link

Backwards compatibility check does not check for declare or export #257

Closed gbtec-markusmeier closed 1 year ago

gbtec-markusmeier commented 1 year ago

Check list

Environment info

Problem / Steps to reproduce

When loading forgit, backwards compatilibility checks reports variables not being exported although they are.

Reason is that bash's export does not return FORGIT_PAGER="less", but:

We should additionally check for export in https://github.com/wfxr/forgit/blob/master/forgit.plugin.zsh#L25.

Checking for declare -x won't be necessary when we fix https://github.com/wfxr/forgit/issues/256.

$ bash --version
GNU bash, version 5.1.16(1)-release (x86_64-pc-linux-gnu)