Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
98da5626
Kaydet (Commit)
98da5626
authored
Mar 23, 2005
tarafından
Martin v. Löwis
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Make dist_files a triple, with the Python target version included,
so that bdist_wininst can specify 'any'.
üst
c8734a72
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
38 additions
and
14 deletions
+38
-14
bdist_dumb.py
Lib/distutils/command/bdist_dumb.py
+7
-1
bdist_rpm.py
Lib/distutils/command/bdist_rpm.py
+12
-1
bdist_wininst.py
Lib/distutils/command/bdist_wininst.py
+5
-1
sdist.py
Lib/distutils/command/sdist.py
+1
-1
upload.py
Lib/distutils/command/upload.py
+4
-7
dist.py
Lib/distutils/dist.py
+9
-3
No files found.
Lib/distutils/command/bdist_dumb.py
Dosyayı görüntüle @
98da5626
...
...
@@ -13,6 +13,7 @@ from distutils.core import Command
from
distutils.util
import
get_platform
from
distutils.dir_util
import
create_tree
,
remove_tree
,
ensure_relative
from
distutils.errors
import
*
from
distutils.sysconfig
import
get_python_version
from
distutils
import
log
class
bdist_dumb
(
Command
):
...
...
@@ -119,7 +120,12 @@ class bdist_dumb (Command):
# Make the archive
filename
=
self
.
make_archive
(
pseudoinstall_root
,
self
.
format
,
root_dir
=
archive_root
)
self
.
distribution
.
dist_files
.
append
((
'bdist_dumb'
,
filename
))
if
self
.
distribution
.
has_ext_modules
():
pyversion
=
get_python_version
()
else
:
pyversion
=
'any'
self
.
distribution
.
dist_files
.
append
((
'bdist_dumb'
,
pyversion
,
filename
))
if
not
self
.
keep_temp
:
remove_tree
(
self
.
bdist_dir
,
dry_run
=
self
.
dry_run
)
...
...
Lib/distutils/command/bdist_rpm.py
Dosyayı görüntüle @
98da5626
...
...
@@ -15,6 +15,7 @@ from distutils.debug import DEBUG
from
distutils.util
import
get_platform
from
distutils.file_util
import
write_file
from
distutils.errors
import
*
from
distutils.sysconfig
import
get_python_version
from
distutils
import
log
class
bdist_rpm
(
Command
):
...
...
@@ -346,6 +347,10 @@ class bdist_rpm (Command):
srpms
=
glob
.
glob
(
os
.
path
.
join
(
rpm_dir
[
'SRPMS'
],
"*.rpm"
))
assert
len
(
srpms
)
==
1
,
\
"unexpected number of SRPM files found:
%
s"
%
srpms
dist_file
=
(
'bdist_rpm'
,
''
,
os
.
path
.
join
(
self
.
dist_dir
,
os
.
path
.
basename
(
srpms
[
0
])))
self
.
distribution
.
dist_files
.
append
(
dist_file
)
self
.
move_file
(
srpms
[
0
],
self
.
dist_dir
)
if
not
self
.
source_only
:
...
...
@@ -356,9 +361,15 @@ class bdist_rpm (Command):
rpms
.
remove
(
debuginfo
[
0
])
assert
len
(
rpms
)
==
1
,
\
"unexpected number of RPM files found:
%
s"
%
rpms
dist_file
=
(
'bdist_rpm'
,
get_python_version
(),
os
.
path
.
join
(
self
.
dist_dir
,
os
.
path
.
basename
(
rpms
[
0
])))
self
.
distribution
.
dist_files
.
append
(
dist_file
)
self
.
move_file
(
rpms
[
0
],
self
.
dist_dir
)
self
.
distribution
.
dist_files
.
append
((
'bdist_rpm'
,
rpms
[
0
]))
if
debuginfo
:
dist_file
=
(
'bdist_rpm'
,
get_python_version
(),
os
.
path
.
join
(
self
.
dist_dir
,
os
.
path
.
basename
(
debuginfo
[
0
])))
self
.
move_file
(
debuginfo
[
0
],
self
.
dist_dir
)
# run()
...
...
Lib/distutils/command/bdist_wininst.py
Dosyayı görüntüle @
98da5626
...
...
@@ -162,7 +162,11 @@ class bdist_wininst (Command):
root_dir
=
self
.
bdist_dir
)
# create an exe containing the zip-file
self
.
create_exe
(
arcname
,
fullname
,
self
.
bitmap
)
self
.
distribution
.
dist_files
.
append
((
'bdist_wininst'
,
if
self
.
distribution
.
has_ext_modules
():
pyversion
=
get_python_version
()
else
:
pyversion
=
'any'
self
.
distribution
.
dist_files
.
append
((
'bdist_wininst'
,
pyversion
,
self
.
get_installer_filename
(
fullname
)))
# remove the zip-file again
log
.
debug
(
"removing temporary file '
%
s'"
,
arcname
)
...
...
Lib/distutils/command/sdist.py
Dosyayı görüntüle @
98da5626
...
...
@@ -449,7 +449,7 @@ class sdist (Command):
for
fmt
in
self
.
formats
:
file
=
self
.
make_archive
(
base_name
,
fmt
,
base_dir
=
base_dir
)
archive_files
.
append
(
file
)
self
.
distribution
.
dist_files
.
append
((
'sdist'
,
file
))
self
.
distribution
.
dist_files
.
append
((
'sdist'
,
''
,
file
))
self
.
archive_files
=
archive_files
...
...
Lib/distutils/command/upload.py
Dosyayı görüntüle @
98da5626
...
...
@@ -4,7 +4,6 @@ Implements the Distutils 'upload' subcommand (upload package to PyPI)."""
from
distutils.errors
import
*
from
distutils.core
import
Command
from
distutils.sysconfig
import
get_python_version
from
distutils.spawn
import
spawn
from
distutils
import
log
from
md5
import
md5
...
...
@@ -61,10 +60,10 @@ class upload(Command):
def
run
(
self
):
if
not
self
.
distribution
.
dist_files
:
raise
DistutilsOptionError
(
"No dist file created in earlier command"
)
for
command
,
filename
in
self
.
distribution
.
dist_files
:
self
.
upload_file
(
command
,
filename
)
for
command
,
pyversion
,
filename
in
self
.
distribution
.
dist_files
:
self
.
upload_file
(
command
,
pyversion
,
filename
)
def
upload_file
(
self
,
command
,
filename
):
def
upload_file
(
self
,
command
,
pyversion
,
filename
):
# Sign if requested
if
self
.
sign
:
spawn
((
"gpg"
,
"--detach-sign"
,
"-a"
,
filename
),
...
...
@@ -79,7 +78,7 @@ class upload(Command):
'version'
:
self
.
distribution
.
get_version
(),
'content'
:(
os
.
path
.
basename
(
filename
),
content
),
'filetype'
:
command
,
'pyversion'
:
get_python_version
()
,
'pyversion'
:
pyversion
,
'md5_digest'
:
md5
(
content
)
.
hexdigest
(),
}
comment
=
''
...
...
@@ -89,8 +88,6 @@ class upload(Command):
comment
=
'built for
%
s
%
s'
%
(
dist
,
version
)
elif
command
==
'bdist_dumb'
:
comment
=
'built for
%
s'
%
platform
.
platform
(
terse
=
1
)
elif
command
==
'sdist'
:
data
[
'pyversion'
]
=
''
data
[
'comment'
]
=
comment
if
self
.
sign
:
...
...
Lib/distutils/dist.py
Dosyayı görüntüle @
98da5626
...
...
@@ -177,9 +177,15 @@ Common commands: (see '--help-commands' for more)
# command_options = { command_name : { option : (source, value) } }
self
.
command_options
=
{}
# 'dist_files' is the list of (command, file) that have been created
# by any dist commands run so far. This is filled regardless
# of whether the run is dry or not.
# 'dist_files' is the list of (command, pyversion, file) that
# have been created by any dist commands run so far. This is
# filled regardless of whether the run is dry or not. pyversion
# gives sysconfig.get_python_version() if the dist file is
# specific to a Python version, 'any' if it is good for all
# Python versions on the target platform, and '' for a source
# file. pyversion should not be used to specify minimum or
# maximum required Python versions; use the metainfo for that
# instead.
self
.
dist_files
=
[]
# These options are really the business of various commands, rather
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment