snapcrafters / nano

A community-maintained package to easily install Nano on Linux
https://snapcraft.io/nano
MIT License
3 stars 5 forks source link

Use dialog(1) for nanorc workaround prompt #4

Closed brlin-tw closed 5 years ago

brlin-tw commented 5 years ago
$ nano
nano-launch: It appears that you have a nanorc file in your home directory, however due to snapd's security confinement it is not accessible by the snap.
nano-launch: If you wish to use it you have to create a hardlink manually by running the `ln /home/buo-ren/.nanorc /home/buo-ren/snap/nano/common/.config/nano/nanorc` command in a terminal.
nano-launch: To silent this warning without linking create a blank file at /home/buo-ren/snap/nano/common/.config/nano/nanorc.

Press Enter to continue:

The previous prompt is not pretty, let's make it better.

This patch re-implements the prompt using dialog(1), to draw a pretty dialog box before launching nano(also a curses application).

default

Signed-off-by: 林博仁(Buo-ren, Lin) Buo.Ren.Lin@gmail.com