<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/NetworkManager.git/examples, branch lr/python3</title>
<subtitle>gitlab.freedesktop.org: NetworkManager/NetworkManager.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/'/>
<entry>
<title>all: use the elvis operator wherever possible</title>
<updated>2018-05-10T12:36:58+00:00</updated>
<author>
<name>Lubomir Rintel</name>
<email>lkundrak@v3.sk</email>
</author>
<published>2018-04-24T09:20:03+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=e69d386975be997d3d840de9045e51521ac4474c'/>
<id>e69d386975be997d3d840de9045e51521ac4474c</id>
<content type='text'>
Coccinelle:

  @@
  expression a, b;
  @@
  -a ? a : b
  +a ?: b

Applied with:

  spatch --sp-file ternary.cocci --in-place --smpl-spacing --dir .

With some manual adjustments on spots that Cocci didn't catch for
reasons unknown.

Thanks to the marvelous effort of the GNU compiler developer we can now
spare a couple of bits that could be used for more important things,
like this commit message. Standards commitees yet have to catch up.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Coccinelle:

  @@
  expression a, b;
  @@
  -a ? a : b
  +a ?: b

Applied with:

  spatch --sp-file ternary.cocci --in-place --smpl-spacing --dir .

With some manual adjustments on spots that Cocci didn't catch for
reasons unknown.

Thanks to the marvelous effort of the GNU compiler developer we can now
spare a couple of bits that could be used for more important things,
like this commit message. Standards commitees yet have to catch up.
</pre>
</div>
</content>
</entry>
<entry>
<title>all: remove consecutive empty lines</title>
<updated>2018-04-30T14:24:52+00:00</updated>
<author>
<name>Beniamino Galvani</name>
<email>bgalvani@redhat.com</email>
</author>
<published>2018-04-30T11:46:24+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=1b5925ce881370a1aba347cea0afe61e6316e81a'/>
<id>1b5925ce881370a1aba347cea0afe61e6316e81a</id>
<content type='text'>
Normalize coding style by removing consecutive empty lines from C
sources and headers.

https://github.com/NetworkManager/NetworkManager/pull/108
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Normalize coding style by removing consecutive empty lines from C
sources and headers.

https://github.com/NetworkManager/NetworkManager/pull/108
</pre>
</div>
</content>
</entry>
<entry>
<title>libnm: rework checkpoint API</title>
<updated>2018-04-04T12:02:13+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2018-04-04T11:33:53+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=735dc41bd057301d65c3d22ca5c0689fa4cdebec'/>
<id>735dc41bd057301d65c3d22ca5c0689fa4cdebec</id>
<content type='text'>
The libnm API fir checkpoints was only introduced with 1.11. It
is not yet stable, so there is still time to adjust it. Note that
this changes API/ABI of the development branch.

Changes:

- we only add async variants of the checkpoint functions. I believe
  that synchronous D-Bus methods are fundamentally flawed, because
  they mess up the ordering of events.
  Rename the async functions by removing the "_async" suffix. This
  matches glib style, for which the async form is also not specially
  marked.

- for function that refere to a particular checkpoint (rollback and
  destroy), accept the D-Bus path as string, instead of an NMCheckpoint
  instance. This form is more flexible, because it allows to use
  the function without having a NMCheckpoint instance at hand. On the
  other hand, if one has a NMCheckpoint instance, he can trivially
  obtain the path to make the call.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The libnm API fir checkpoints was only introduced with 1.11. It
is not yet stable, so there is still time to adjust it. Note that
this changes API/ABI of the development branch.

Changes:

- we only add async variants of the checkpoint functions. I believe
  that synchronous D-Bus methods are fundamentally flawed, because
  they mess up the ordering of events.
  Rename the async functions by removing the "_async" suffix. This
  matches glib style, for which the async form is also not specially
  marked.

- for function that refere to a particular checkpoint (rollback and
  destroy), accept the D-Bus path as string, instead of an NMCheckpoint
  instance. This form is more flexible, because it allows to use
  the function without having a NMCheckpoint instance at hand. On the
  other hand, if one has a NMCheckpoint instance, he can trivially
  obtain the path to make the call.
</pre>
</div>
</content>
</entry>
<entry>
<title>examples: improve checkpoint.py for python/gi</title>
<updated>2018-04-04T12:02:13+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2018-03-28T16:52:06+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=2a30bef85690619dfbcab5dea282d7450f4b96d5'/>
<id>2a30bef85690619dfbcab5dea282d7450f4b96d5</id>
<content type='text'>
- make python2 and python3 compatible
- support Checkpoint create flags (requires recent libnm for GI
  of flags)
- support adjust-rollback-timeout command
- print elapsed time in show output
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- make python2 and python3 compatible
- support Checkpoint create flags (requires recent libnm for GI
  of flags)
- support adjust-rollback-timeout command
- print elapsed time in show output
</pre>
</div>
</content>
</entry>
<entry>
<title>examples: add python utils for examples</title>
<updated>2018-04-04T12:02:13+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2018-03-28T17:00:22+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=d14b9b821529e5efebdb3d99c022b16803866d52'/>
<id>d14b9b821529e5efebdb3d99c022b16803866d52</id>
<content type='text'>
We need common operations from the python scripts.
For example, to print the boot-time.

Move such utils to a separate nmex.py file ("ex" for
example). This file should contain helper functions that
are pure python (or, if the have requirements, load them
only on demand, so that examples that need those have
additional dependencies). It should also be simple to extract
individual helpers from nmex, so that the user can take an
example, merge parts of nmex.py in, and modify it to his needs.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We need common operations from the python scripts.
For example, to print the boot-time.

Move such utils to a separate nmex.py file ("ex" for
example). This file should contain helper functions that
are pure python (or, if the have requirements, load them
only on demand, so that examples that need those have
additional dependencies). It should also be simple to extract
individual helpers from nmex, so that the user can take an
example, merge parts of nmex.py in, and modify it to his needs.
</pre>
</div>
</content>
</entry>
<entry>
<title>checkpoint: generate GIR information for NMCheckpointCreateFlags</title>
<updated>2018-04-04T12:02:13+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2018-03-28T15:24:30+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=ab8312a18e8b281a62f39ce59a077fda77943187'/>
<id>ab8312a18e8b281a62f39ce59a077fda77943187</id>
<content type='text'>
Note that this changes API for checkpoint_create_async() in Python
via GIR. Previously it would require an integer argument, now a flags
argument. But this API is still unstable, it will be introduced with
1.12.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Note that this changes API for checkpoint_create_async() in Python
via GIR. Previously it would require an integer argument, now a flags
argument. But this API is still unstable, it will be introduced with
1.12.
</pre>
</div>
</content>
</entry>
<entry>
<title>all: drop trailing spaces</title>
<updated>2018-02-07T12:32:04+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2018-02-02T10:34:55+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=28da0154fcf005a8391a540f2c5a5055ca1da33f'/>
<id>28da0154fcf005a8391a540f2c5a5055ca1da33f</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>all: replace non-leading tabs with spaces</title>
<updated>2018-02-07T12:32:04+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2018-02-02T09:55:34+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=e4839accf5a5b470b9bf2287f0269ddc4ce0f91b'/>
<id>e4839accf5a5b470b9bf2287f0269ddc4ce0f91b</id>
<content type='text'>
We commonly only allow tabs at the beginning of a line, not
afterwards. The reason for this style is so that the code
looks formated right with tabstop=4 and tabstop=8.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We commonly only allow tabs at the beginning of a line, not
afterwards. The reason for this style is so that the code
looks formated right with tabstop=4 and tabstop=8.
</pre>
</div>
</content>
</entry>
<entry>
<title>version: drop NM_VERSION_MAX_ALLOWED defines for internal build</title>
<updated>2018-01-23T09:50:34+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2018-01-16T14:42:43+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=9ef17869b5fa775bd7f1da14471f52775efe1017'/>
<id>9ef17869b5fa775bd7f1da14471f52775efe1017</id>
<content type='text'>
It already defaults to the right value. We only need to define
NM_VERSION_MIN_REQUIRED, so that parts of our internal build
can make use of deprecated API.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It already defaults to the right value. We only need to define
NM_VERSION_MIN_REQUIRED, so that parts of our internal build
can make use of deprecated API.
</pre>
</div>
</content>
</entry>
<entry>
<title>version: combine NM_VERSION_CUR_STABLE and NM_VERSION_NEXT_STABLE</title>
<updated>2018-01-23T09:50:34+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2018-01-16T14:19:12+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=8a040c6883936e9d76ef072424659fa969c3f945'/>
<id>8a040c6883936e9d76ef072424659fa969c3f945</id>
<content type='text'>
We don't need to have two version defines "CUR" and "NEXT".

The main purpose of these macros (if not their only), is to
make NM_AVAILABLE_IN_* and NM_DEPRECATED_IN_* macros work.

1) At the precise commit of a release, "CUR" and "NEXT" must be identical,
because whenever the user configures NM_VERSION_MIN_REQUIRED and
NM_VERSION_MAX_ALLOWED, then they both compare against the current
version, at which point "CUR" == "NEXT".

2) Every other commit aside the release, is a development version that leads
up the the next coming release. But as far as versioning is concerned, such
a development version should be treated like that future release. It's unstable
API and it may or may not be close to later API of the release. But
we shall treat it as that version. Hence, also in this case, we want to
set both "NM_VERSION_CUR_STABLE" and again NEXT to the future version.

This makes NM_VERSION_NEXT_STABLE redundant.

Previously, the separation between current and next version would for
example allow that NM_VERSION_CUR_STABLE is the previously release
stable API, and NM_VERSION_NEXT_STABLE is the version of the next upcoming
stable API. So, we could allow "examples" to make use of development
API, but other(?) internal code still restrict to unstable API. But it's
unclear which other code would want to avoid current development.

Also, the points 1) and 2) were badly understood. Note that for our
previousy releases, we usually didn't bump the macros at the stable
release (and if we did, we didn't set them to be the same). While using
two macros might be more powerful, it is hard to grok and easy to
forget to bump the macros a the right time. One macro shall suffice.

All this also means, that *immediately* after making a new release, we shall
bump the version number in `configure.ac` and "NM_VERSION_CUR_STABLE".
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We don't need to have two version defines "CUR" and "NEXT".

The main purpose of these macros (if not their only), is to
make NM_AVAILABLE_IN_* and NM_DEPRECATED_IN_* macros work.

1) At the precise commit of a release, "CUR" and "NEXT" must be identical,
because whenever the user configures NM_VERSION_MIN_REQUIRED and
NM_VERSION_MAX_ALLOWED, then they both compare against the current
version, at which point "CUR" == "NEXT".

2) Every other commit aside the release, is a development version that leads
up the the next coming release. But as far as versioning is concerned, such
a development version should be treated like that future release. It's unstable
API and it may or may not be close to later API of the release. But
we shall treat it as that version. Hence, also in this case, we want to
set both "NM_VERSION_CUR_STABLE" and again NEXT to the future version.

This makes NM_VERSION_NEXT_STABLE redundant.

Previously, the separation between current and next version would for
example allow that NM_VERSION_CUR_STABLE is the previously release
stable API, and NM_VERSION_NEXT_STABLE is the version of the next upcoming
stable API. So, we could allow "examples" to make use of development
API, but other(?) internal code still restrict to unstable API. But it's
unclear which other code would want to avoid current development.

Also, the points 1) and 2) were badly understood. Note that for our
previousy releases, we usually didn't bump the macros at the stable
release (and if we did, we didn't set them to be the same). While using
two macros might be more powerful, it is hard to grok and easy to
forget to bump the macros a the right time. One macro shall suffice.

All this also means, that *immediately* after making a new release, we shall
bump the version number in `configure.ac` and "NM_VERSION_CUR_STABLE".
</pre>
</div>
</content>
</entry>
</feed>
