NetworkManager/clients
Thomas Haller 0055d8ed58 cli: don't fail removing non-existing option (pt1)
Part 1, which addresses the issue for simple properties that have
a plain remove-by-value function.

Rationale:

Removing a value/index that does not exist should not be a failure.

Woule you like:

    $ nmcli connection modify "$PROFILE" autoconnect no
    $ nmcli connection modify "$PROFILE" autoconnect no
    Error: autoconnect is already disabled

So, why would it be a good idea to fail during

    $ nmcli connection modify "$PROFILE" -vpn.data ca
    $ nmcli connection modify "$PROFILE" -vpn.data ca
    Error: failed to remove a value from vpn.data: invalid option 'ca'.

Generally, it should not be an error to remove an option, as long
as the option itself is valid. For example,

    $ nmcli connection modify "$PROFILE" -vlan.ingress-priority-map bogus

should fail, but

    $ nmcli connection modify "$PROFILE" -vlan.ingress-priority-map 1:5

should succeed even if there was nothing to remove.
2019-03-25 09:12:32 +01:00
..
cli cli/wireguard: add import functionality for WireGuard 2019-03-07 22:22:39 +01:00
common cli: don't fail removing non-existing option (pt1) 2019-03-25 09:12:32 +01:00
tests cli/tests: fix cli tests after changing Polish translations 2019-02-25 16:20:59 +01:00
tui libnm,core: use _nm_utils_ascii_str_to_uint64() instead of strtol() 2019-02-12 08:50:28 +01:00
meson.build build: meson: Add trailing commas 2018-12-20 13:50:34 +01:00
nm-online.c nm-online: sort options in man page and program help 2018-11-05 09:32:20 +01:00