Добавлено подтверждение отправки пакета в индекс #2

Теперь перед загрузкой на Pypi у пользователя будет спрашиваться подтверждение. Для TestPypi подтверждение не требуется
This commit is contained in:
Ilia Miheev
2025-10-06 21:46:20 +03:00
parent d69ddef214
commit f55533fd20
+4
View File
@@ -35,6 +35,10 @@ def uploadi():
if args.t: if args.t:
command = 'twine upload --repository-url https://test.pypi.org/legacy/ dist/*' command = 'twine upload --repository-url https://test.pypi.org/legacy/ dist/*'
else: else:
ask = input('Вы уверены, что хотите выгрузить на PyPI? (y/n): ')
if ask.lower() != 'y':
print('Выгрузка отменена.')
return
command = 'twine upload dist/*' command = 'twine upload dist/*'
# Выполняем выгрузку # Выполняем выгрузку