mmtrt / notepad-plus-plus-snap

Unofficial snap repo for notepad-plus-plus snap

Home Page:https://snapcraft.io/notepad-plus-plus

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

No protocol specified

Qarj opened this issue · comments

I'm running Ubuntu 18.04 and installed Notepad-Plus-Plus using Ubuntu Software since it is one of the featured apps in Editor's Picks.

I need to edit some Apache configuration files, so I need to start it with root privileges - but am getting an error when I do this:

test@uk-ubuntu-test:~$ sudo notepad-plus-plus
No protocol specified

I tried running these 4 commands to see if they would help, but it didn't:

test@uk-ubuntu-test:~$ sudo snap connect notepad-plus-plus:hardware-observe
test@uk-ubuntu-test:~$ sudo snap connect notepad-plus-plus:removable-media
test@uk-ubuntu-test:~$ sudo snap connect notepad-plus-plus:process-control
test@uk-ubuntu-test:~$ sudo snap connect notepad-plus-plus:cups-control

I also tried lxqt-sudo:

test@uk-ubuntu-test:~$ lxqt-sudo notepad-plus-plus

No protocol specified

Ultimately I'd like to create a desktop shortcut to start it as root:

sudo_npp.desktop

[Desktop Entry]
Name=Sudo NPP
Exec=lxqt-sudo notepad-plus-plus
Type=Application

I can start it ok without using sudo:

notepad-plus-plus

snap won't work like that when running it with sudo command to get full access to system but still this snap has strict confinement so it won't be able to access data from root partition.

though you can try mount bind working dir on root to home

sudo mount -obind /path/to/apache/config/files /home/username/xyz

edit files from /home/username/xyz

I don't have any plans for changing this snap as classic confinement ATM which would have full access to the system files if this snap was classic.