File tree Expand file tree Collapse file tree 4 files changed +22
-20
lines changed Expand file tree Collapse file tree 4 files changed +22
-20
lines changed Original file line number Diff line number Diff line change @@ -41,11 +41,6 @@ exclude .svn
41
41
exclude .hg
42
42
exclude appointment/__pycache__
43
43
exclude appointment/migrations/__pycache__
44
- exclude appointment/django_appointment.egg-info/PKG-INFO
45
- exclude appointment/django_appointment.egg-info/SOURCES.txt
46
- exclude appointment/django_appointment.egg-info/dependency_links.txt
47
- exclude appointment/django_appointment.egg-info/requires.txt
48
- exclude appointment/django_appointment.egg-info/top_level.txt
49
44
50
45
# Recursive exclusions
51
46
recursive-exclude appointment/migrations *.py
Original file line number Diff line number Diff line change 4
4
__description__ = "Managing appointment scheduling with customizable slots, staff features, and conflict handling."
5
5
__package_name__ = "django-appointment"
6
6
__url__ = "https://github.com/adamspd/django-appointment"
7
- __version__ = "2.1.1"
7
+ __version__ = "2.1.2"
8
+ __test_version__ = True
Original file line number Diff line number Diff line change 1
1
import requests
2
- from appointment import __version__ , __package_name__
2
+ from appointment import __version__ , __package_name__ , __test_version__
3
3
4
- package_name = __package_name__
5
- current_version = __version__
6
4
7
- response = requests .get (f"https://pypi.org/pypi/{ package_name } /json" )
5
+ def check_package_version (package_name , current_version ):
6
+ version_exists = False
8
7
9
- version_exists = False
10
-
11
- if response .status_code == 200 :
12
- released_versions = response .json ()["releases" ].keys ()
13
- if current_version in released_versions :
14
- print (f"Version { current_version } already exists on PyPI!" )
8
+ if __test_version__ :
9
+ print ("Test version, skipping PyPI check." )
15
10
version_exists = True
11
+ else :
12
+ response = requests .get (f"https://pypi.org/pypi/{ package_name } /json" )
13
+
14
+ if response .status_code == 200 :
15
+ released_versions = response .json ()["releases" ].keys ()
16
+ if current_version in released_versions :
17
+ print (f"Version { current_version } already exists on PyPI!" )
18
+ version_exists = True
19
+
20
+ # Output for GitHub Actions
21
+ print (f"::set-output name=version_exists::{ version_exists } " )
22
+
16
23
17
- # Output for GitHub Actions
18
- print (f"::set-output name=version_exists::{ version_exists } " )
24
+ check_package_version (__package_name__ , __version__ )
Original file line number Diff line number Diff line change 1
- Django == 5.0
1
+ Django == 4.2.8
2
2
Pillow == 10.1.0
3
3
phonenumbers == 8.13.26
4
4
django-phonenumber-field == 7.2.0
5
- babel == 2.13.1
5
+ babel == 2.14.0
6
6
setuptools == 69.0.2
7
7
pytz ~= 2023.3.post1
You can’t perform that action at this time.
0 commit comments