Skip to content

Commit 8af403c

Browse files
authored
Merge pull request #1838 from python-gitlab/jlvillal/version_mv
chore: rename `gitlab/__version__.py` to `gitlab/_version.py`
2 parents fe14dd5 + b981ce7 commit 8af403c

File tree

7 files changed

+6
-6
lines changed

7 files changed

+6
-6
lines changed

CONTRIBUTING.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ This avoids triggering incorrect version bumps and releases without functional c
153153
The release workflow uses `python-semantic-release
154154
<https://python-semantic-release.readthedocs.io>`_ and does the following:
155155

156-
* Bumps the version in ``__version__.py`` and adds an entry in ``CHANGELOG.md``,
156+
* Bumps the version in ``_version.py`` and adds an entry in ``CHANGELOG.md``,
157157
* Commits and tags the changes, then pushes to the main branch as the ``github-actions`` user,
158158
* Creates a release from the tag and adds the changelog entry to the release notes,
159159
* Uploads the package as assets to the GitHub release,

gitlab/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
from typing import Any
2121

2222
import gitlab.config # noqa: F401
23-
from gitlab.__version__ import ( # noqa: F401
23+
from gitlab._version import ( # noqa: F401
2424
__author__,
2525
__copyright__,
2626
__email__,
File renamed without changes.

gitlab/const.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
# You should have received a copy of the GNU Lesser General Public License
1616
# along with this program. If not, see <http://www.gnu.org/licenses/>.
1717

18-
from gitlab.__version__ import __title__, __version__
18+
from gitlab._version import __title__, __version__
1919

2020
# NOTE(jlvillal): '_DEPRECATED' only affects users accessing constants via the
2121
# top-level gitlab.* namespace. See 'gitlab/__init__.py:__getattr__()' for the

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ ignore_errors = true
3838

3939
[tool.semantic_release]
4040
branch = "main"
41-
version_variable = "gitlab/__version__.py:__version__"
41+
version_variable = "gitlab/_version.py:__version__"
4242
commit_subject = "chore: release v{version}"
4343
commit_message = ""
4444

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
def get_version() -> str:
88
version = ""
9-
with open("gitlab/__version__.py") as f:
9+
with open("gitlab/_version.py") as f:
1010
for line in f:
1111
if line.startswith("__version__"):
1212
version = eval(line.split("=")[-1])

tests/smoke/test_dists.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
import pytest
77
from setuptools import sandbox
88

9-
from gitlab import __title__, __version__
9+
from gitlab._version import __title__, __version__
1010

1111
DIST_DIR = Path("dist")
1212
DOCS_DIR = "docs"

0 commit comments

Comments
 (0)