Setting nano as default editor not working for crontab with fish shell

Solution 1:

set -U VISUAL nano only sets the variable within Fish. If you want to make it visible also in binaries started by the shell you need to export it, e.g. by using set -Ux VISUAL nano.

For more details

  • Variable Scope
  • Exporting Variables