Skip to content

Add support for KDE neon#57

Open
lleaff wants to merge 1 commit intojblakeman:masterfrom
lleaff:master
Open

Add support for KDE neon#57
lleaff wants to merge 1 commit intojblakeman:masterfrom
lleaff:master

Conversation

@lleaff
Copy link

@lleaff lleaff commented Mar 29, 2017

When running apt-select on KDE neon you get a "Must be an Ubuntu OS" error.
KDE neon is based on Ubuntu LTS but there doesn't seem to be a standard way to tell from the CLI.

$ cat /etc/issue
KDE neon 5.9 \n \l

$ lsb_release -a
Distributor ID: neon
Description:    KDE neon User Edition 5.9
Release:        16.04
Codename:       xenial

There is a hint in the kernel version name but I have doubts on how reliable that info is:

$ uname -v
#88-Ubuntu SMP Wed Mar 8 16:34:45 UTC 2017

Thus I added a check against 'neon' in the code.

Copy link
Owner

@jblakeman jblakeman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for submitting this.

I'm hesitant to keep a static list of Ubuntu variants that follow this behavior. Looking at the output of uname -v on 12.04, 14.04 and 16.04, the first fields all seem to match the pattern: #[0-9]+-Ubuntu, so one might think it would be at least somewhat reliable to parse on most if not all Ubuntu variations.

I lean toward first parsing the output of uname -v as a fall back (if dist != 'Ubuntu') before raising the ValueError.

@lleaff
Copy link
Author

lleaff commented Apr 3, 2017

I can understand these reservations.
With the kernel version-check, I'd be afraid of false positives, e.g. a distro that somehow uses a kernel compiled for Ubuntu but is actually not Ubuntu-like at all in the userspace.
Either way, what do you think of giving the user the option to bypass this Ubuntu check? Could be with a confirmation prompt, or a "--force" style switch.

@jblakeman
Copy link
Owner

I like the idea of --force. However, we'd need to force the user to provide a default series (e.g. Xenial) if they aren't using --ping-only. #39 mentions this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Comments