Commit Graph
362 Commits
Author SHA1 Message Date
Athanasius ce9e7985c7 Release 5.1.0: Post-release bump of appversion to next-beta0 2021-06-04 19:26:31 +01:00
Athanasius 13119b9509 Release 5.1.0: *not* 5.0.5. We want the Minor bump. 2021-06-04 14:02:59 +01:00
Athanasius 34fe350a84 Release 5.0.5: appversion and changelog 2021-06-04 13:42:23 +01:00
Athanasius 170128198f appversion: post-release bump to 5.0.5-beta0 2021-05-27 18:18:04 +01:00
Athanasius 2ba8cf1ea8 Release 5.0.4: appversion and changelog 2021-05-27 17:53:58 +01:00
Athanasius 186668ef4d appversion: post-release bump to 5.0.4-beta0 2021-05-27 15:31:38 +01:00
Athanasius 6bac280a43 Release 5.0.3: No longer an -rc1 2021-05-27 15:05:59 +01:00
Athanasius 8a3351869f Release 5.0.3: appversion and changelog 2021-05-27 14:17:08 +01:00
Athanasius efcf5dda2c appversion 'DIRTY': Separator must be . 2021-05-27 12:46:46 +01:00
Athanasius 4d5d9ae645 config: appversion: Use +DIRTY to ensure SemVer compliance.
It's also more succinct.  We know what it means.
2021-05-27 09:21:13 +01:00
Athanasius 69d8270e8f config: Rework 'git but dirty?' check to handle 'no git'
`shorthash` was still `None` if no git, so we then tried to concatenate
`NoneType` and `str` which is verbotten.

There's no point using git to detect dirtyness if `shorthash` is None
because that itself indicates no git available.
2021-05-21 16:55:10 +01:00
Athanasius eb4cbded7a Post-release appversion bump
I'm trying out a new policy of bumping to patch+1 and -beta0 after a
stable release.  Makes it more obvious when I was testing, especially
over EDDN (which doesn't get sent the +buildmeta).
2021-05-21 15:36:53 +01:00
Athanasius fd5a721b81 Release 5.0.2: appversion and changelog 2021-05-21 14:57:27 +01:00
A_D 924221f063 Show whether or not the git wdir is dirty in version
Closes #1073
2021-05-21 08:39:13 +02:00
Athanasius f987208a39 Release 5.0.1: appversion and changelog 2021-05-17 15:14:56 +01:00
Athanasius 6c590b0c39 Release 5.0.0: appversion and ChangeLog 2021-05-12 14:19:33 +01:00
Athanasius bbd1d7a52b Pre-Release 5.0.0-rc1 appversion 2021-05-07 19:58:16 +01:00
A_D d3ffe6f0d9 Removed useless check, added doc comments 2021-05-07 14:27:32 +02:00
A_D 985794fbcb Ensure that Section exists on linuxconf
When starting EDMC for the first time, linuxconf creates the required
file automatically but does _not_ create our config section. This causes
a keyerror on any access to config.

Simple solution, test that the section exists, if it doesnt, create it
(and backup any existing file beforehand)
2021-05-07 12:58:10 +02:00
Athanasius 6cf1a30482 Pre-Release 5.0.0-beta8: appversion and changelog 2021-05-06 08:51:59 +01:00
Athanasius f9db23e25d Pre-Release 5.0.0-beta7: appversion and changelog 2021-05-01 17:56:13 +01:00
Athanasius e363e1d0ae Pre-Release 5.0.0-beta6: appversion and changelog 2021-04-19 12:40:18 +01:00
A_D f99b0445ca Also save on delete 2021-04-13 00:35:01 +02:00
A_D d4e7395a44 Ensured all sets are flushed to disk on linux
Fixes 1002
2021-04-13 00:31:58 +02:00
Athanasius ae2bbc8929 Set config flag for --force-edmc-protocol so protocol.py can test it 2021-04-12 16:25:53 +01:00
Athanasius 6532a0f0ed Release 5.0.0-beta5: appversion and changelog 2021-04-12 13:51:26 +01:00
Athanasius b66d599508 Pre-Release 5.0.0-beta4: appversion and changelog 2021-04-12 08:31:47 +01:00
Athanasius cc809de042 config.py: Remove 'protoype' comment about appversion being a function 2021-04-12 08:31:46 +01:00
Athanasius c1cf90bda3 Add comment about using .parent because non-main script is in library.zip 2021-04-12 08:31:46 +01:00
Athanasius f16a367986 Use full path to open .gitversion out of paranoia. 2021-04-12 08:31:46 +01:00
Athanasius 7bbc8e86a2 Pre-Release 5.0.0-beta3: appversion and changelog
# Conflicts:
#	config.py
2021-04-12 08:31:40 +01:00
Athanasius 7bf4fba85a Version to 4.2.0-beta1 to distinguish Python 3.8 builds
* I don't want to be checking something against 4.1.x releases when my
  last build was with Python 3.8.

# Conflicts:
#	config.py

# Conflicts:
#	config.py

# Conflicts:
#	config.py
2021-04-01 14:47:24 +01:00
Athanasius 95458f12c7 Pre-Release 5.0.0-beta2: appversion & changelog 2021-04-01 14:46:43 +01:00
Athanasius 4d1c6906e7 Maybe I should stop putting types on :return: and :param: ... 2021-04-01 14:46:43 +01:00
Athanasius 5de4950fba Change config.appversion() to return semantic_version.Version
As we're changing it to a function at this stage anyway, it might as
well return this type, not a str.
2021-04-01 14:46:43 +01:00
Athanasius e37c635a84 config.py: docstring pass for consistency. 2021-04-01 14:45:52 +01:00
Athanasius 52a64d3fb6 config.py: Last few docstrings
* Implementations of: delete(), save(), close().
* get_config()
2021-04-01 14:45:52 +01:00
Athanasius 6d2a0e29ee Bring MacConfig.set() in line with other implmentations.
* It wasn't doing any value type validation.
* Also dropped the `()` from the 'Implements' lines.
2021-04-01 14:45:52 +01:00
Athanasius 9a185e91ca config.py: Add a lot of docstrings to Config class methods.
I settled on having the full docstring only in the AbstractConfig
definitions.  In the implementations we then have:

"""
<first line same as AbstractConfig>

Implements :meth:`AbstractConfig.<method>`.
"""
2021-04-01 14:45:52 +01:00
Athanasius 9444973ebd config.py: docstring new appversion() and appversion_nobuild() 2021-04-01 14:45:52 +01:00
Athanasius 7a8b1100e9 config.py: Remove static_appversion_nobuild, and point to functions
* Also renamed static_appversion to have leading _ to further discourage
  use.
2021-04-01 14:45:52 +01:00
Athanasius dcc4f1c4f1 Begin converting config.appversion to a function.
In-place converstion done, next will be all the call sites.
2021-04-01 14:45:52 +01:00
Athanasius cc571e44b1 Re-factor git short hash into a config.py function.
This should clear the way for using it in running code when not frozen.
2021-04-01 14:45:52 +01:00
Athanasius 7ad3518a7b config.py: Restor appversion to intended 5.0.0-beta1 for current develop. 2021-04-01 14:45:52 +01:00
Athanasius 6dbdd332be config.py: Silence flake8 complaint about no space at start of comment 2021-04-01 14:45:52 +01:00
Athanasius bfb7780efc Version to 4.2.0-beta1 to distinguish Python 3.8 builds
* I don't want to be checking something against 4.1.x releases when my
  last build was with Python 3.8.

# Conflicts:
#	config.py
2021-04-01 14:45:51 +01:00
Athanasius 87c88b80ea Slightly more paranoia in that NSCFArray check 2021-04-01 14:45:50 +01:00
Athanasius 6a4ab10cd4 Add comment about the __NSCFArray issue 2021-04-01 14:45:50 +01:00
Athanasius 1c269e9f4b Change darwin __raw_get() check for list to check it's not the OTHERS
On darwin this comes back with the type `__NSCFArray`, which I can't
find the definition of (in order to test against it).  So instead let's
check that `res` is not-None, and not one of `str` or `int`, because
then it should be (meant to be) `list`.

Yes, this is weird given the pre-rewrite code is:

```python
        def get(self, key: str) -> Union[None, list, str]:
            """Look up a string configuration value."""
            val = self.settings.get(key)
            if val is None:
                return None

            elif isinstance(val, str):
                return str(val)

            elif isinstance(val, list):
                return list(val)  # make writeable

            else:
                return None
```
But maybe something changed since 3.43 was tested and built.
2021-04-01 14:45:50 +01:00
Athanasius 0f83e5b035 macos config: Respect suppress argument to config.delete()
Else the blind deletion of the shipyard key at startup causes a fatal
exception.
2021-04-01 14:45:50 +01:00