activate.fish: update fish major version check
Use fish's string sub command to get fish's major version from
$FISH_VERSION.
The head program in OpenBSD does not have the -c flag.
Addresses #2892.
@gaborbernat some tests are failing and it does not seem to be related to the changes in this PR. Are you able to look into it and possibly get this merged?
Let's not worry about other tests until you add a test to validate your change.
@gaborbernat
Added a test in test_fish.py to verify that the PATH is reverted to
the original PATH after virtualenv deactivation. This verification
confirms that the _OLD_VIRTUAL_PATH was correctly set in fish during
the activation of the virtualenv.
See if it looks good.