autopub 1.0.0a8__tar.gz → 1.0.0a9__tar.gz
Sign up to get free protection for your applications and to get access to all the features.
- {autopub-1.0.0a8 → autopub-1.0.0a9}/PKG-INFO +1 -1
- {autopub-1.0.0a8 → autopub-1.0.0a9}/autopub/__init__.py +3 -4
- {autopub-1.0.0a8 → autopub-1.0.0a9}/autopub/plugins/__init__.py +1 -1
- {autopub-1.0.0a8 → autopub-1.0.0a9}/autopub/plugins/git.py +5 -6
- {autopub-1.0.0a8 → autopub-1.0.0a9}/pyproject.toml +1 -1
- {autopub-1.0.0a8 → autopub-1.0.0a9}/LICENSE +0 -0
- {autopub-1.0.0a8 → autopub-1.0.0a9}/README.md +0 -0
- {autopub-1.0.0a8 → autopub-1.0.0a9}/autopub/cli/__init__.py +0 -0
- {autopub-1.0.0a8 → autopub-1.0.0a9}/autopub/cli/plugins.py +0 -0
- {autopub-1.0.0a8 → autopub-1.0.0a9}/autopub/exceptions.py +0 -0
- {autopub-1.0.0a8 → autopub-1.0.0a9}/autopub/plugins/bump_version.py +0 -0
- {autopub-1.0.0a8 → autopub-1.0.0a9}/autopub/plugins/pdm.py +0 -0
- {autopub-1.0.0a8 → autopub-1.0.0a9}/autopub/plugins/poetry.py +0 -0
- {autopub-1.0.0a8 → autopub-1.0.0a9}/autopub/plugins/update_changelog.py +0 -0
- {autopub-1.0.0a8 → autopub-1.0.0a9}/autopub/py.typed +0 -0
- {autopub-1.0.0a8 → autopub-1.0.0a9}/autopub/types.py +0 -0
@@ -105,16 +105,15 @@ class Autopub:
|
|
105
105
|
self.release_file.unlink()
|
106
106
|
|
107
107
|
def publish(self, repository: str | None = None) -> None:
|
108
|
-
|
109
|
-
# clear that we are triggering the logic to check the release file?
|
110
|
-
self.release_data
|
108
|
+
release_info = self.release_data
|
111
109
|
|
112
110
|
for plugin in self.plugins:
|
111
|
+
# TODO: maybe pass release info to publish method?
|
113
112
|
if isinstance(plugin, AutopubPackageManagerPlugin):
|
114
113
|
plugin.publish(repository=repository)
|
115
114
|
|
116
115
|
for plugin in self.plugins:
|
117
|
-
plugin.post_publish()
|
116
|
+
plugin.post_publish(release_info)
|
118
117
|
|
119
118
|
self._delete_release_file()
|
120
119
|
|
@@ -32,7 +32,7 @@ class AutopubPlugin:
|
|
32
32
|
def on_release_notes_invalid(self, exception: AutopubException): # pragma: no cover
|
33
33
|
...
|
34
34
|
|
35
|
-
def post_publish(self) -> None: # pragma: no cover
|
35
|
+
def post_publish(self, release_info: ReleaseInfo) -> None: # pragma: no cover
|
36
36
|
...
|
37
37
|
|
38
38
|
|
@@ -1,17 +1,16 @@
|
|
1
1
|
from __future__ import annotations
|
2
2
|
|
3
|
-
from typing import Any
|
4
|
-
|
5
3
|
from autopub.plugins import AutopubPlugin
|
4
|
+
from autopub.types import ReleaseInfo
|
6
5
|
|
7
6
|
|
8
7
|
class GitPlugin(AutopubPlugin):
|
9
|
-
def post_publish(self,
|
8
|
+
def post_publish(self, release_info: ReleaseInfo) -> None:
|
10
9
|
self.run_command(["git", "config", "--global", "user.email", "autopub@autopub"])
|
11
10
|
self.run_command(["git", "config", "--global", "user.name", "autopub"])
|
12
11
|
|
13
|
-
self.run_command(["git", "
|
12
|
+
self.run_command(["git", "tag", release_info.additional_info["new_version"]])
|
14
13
|
|
14
|
+
self.run_command(["git", "add", "--all", "--", ":!main/.autopub"])
|
15
15
|
self.run_command(["git", "commit", "-m", "🤖 autopub publish"])
|
16
|
-
|
17
|
-
self.run_command(["git", "push"])
|
16
|
+
self.run_command(["git", "push", "--tags"])
|
@@ -3,7 +3,7 @@ requires-python = ">=3.8"
|
|
3
3
|
|
4
4
|
[tool.poetry]
|
5
5
|
name = "autopub"
|
6
|
-
version = "1.0.0-alpha.
|
6
|
+
version = "1.0.0-alpha.9"
|
7
7
|
description = "Automatic package release upon pull request merge"
|
8
8
|
authors = ["Justin Mayer <entroP@gmail.com>", "Patrick Arminio <patrick.arminio@gmail.com>"]
|
9
9
|
license = "AGPL-3.0"
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|