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
784ca6c8
Kaydet (Commit)
784ca6c8
authored
Agu 16, 1991
tarafından
Guido van Rossum
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
path.cat --> join
üst
668317db
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
14 additions
and
14 deletions
+14
-14
dircache.py
Lib/dircache.py
+1
-1
dircmp.py
Lib/dircmp.py
+5
-5
glob.py
Lib/glob.py
+2
-2
dirwin.py
Lib/lib-stdwin/dirwin.py
+2
-2
shutil.py
Lib/shutil.py
+2
-2
dirwin.py
Lib/stdwin/dirwin.py
+2
-2
No files found.
Lib/dircache.py
Dosyayı görüntüle @
784ca6c8
...
@@ -32,5 +32,5 @@ opendir = listdir # XXX backward compatibility
...
@@ -32,5 +32,5 @@ opendir = listdir # XXX backward compatibility
def
annotate
(
head
,
list
):
# Add '/' suffixes to directories
def
annotate
(
head
,
list
):
# Add '/' suffixes to directories
for
i
in
range
(
len
(
list
)):
for
i
in
range
(
len
(
list
)):
if
path
.
isdir
(
path
.
cat
(
head
,
list
[
i
])):
if
path
.
isdir
(
path
.
join
(
head
,
list
[
i
])):
list
[
i
]
=
list
[
i
]
+
'/'
list
[
i
]
=
list
[
i
]
+
'/'
Lib/dircmp.py
Dosyayı görüntüle @
784ca6c8
...
@@ -53,8 +53,8 @@ class dircmp():
...
@@ -53,8 +53,8 @@ class dircmp():
dd
.
common_funny
=
[]
dd
.
common_funny
=
[]
#
#
for
x
in
dd
.
common
:
for
x
in
dd
.
common
:
a_path
=
path
.
cat
(
dd
.
a
,
x
)
a_path
=
path
.
join
(
dd
.
a
,
x
)
b_path
=
path
.
cat
(
dd
.
b
,
x
)
b_path
=
path
.
join
(
dd
.
b
,
x
)
#
#
ok
=
1
ok
=
1
try
:
try
:
...
@@ -92,8 +92,8 @@ class dircmp():
...
@@ -92,8 +92,8 @@ class dircmp():
# The hide and ignore properties are inherited from the parent
# The hide and ignore properties are inherited from the parent
dd
.
subdirs
=
{}
dd
.
subdirs
=
{}
for
x
in
dd
.
common_dirs
:
for
x
in
dd
.
common_dirs
:
a_x
=
path
.
cat
(
dd
.
a
,
x
)
a_x
=
path
.
join
(
dd
.
a
,
x
)
b_x
=
path
.
cat
(
dd
.
b
,
x
)
b_x
=
path
.
join
(
dd
.
b
,
x
)
dd
.
subdirs
[
x
]
=
newdd
=
dircmp
()
.
new
(
a_x
,
b_x
)
dd
.
subdirs
[
x
]
=
newdd
=
dircmp
()
.
new
(
a_x
,
b_x
)
newdd
.
hide
=
dd
.
hide
newdd
.
hide
=
dd
.
hide
newdd
.
ignore
=
dd
.
ignore
newdd
.
ignore
=
dd
.
ignore
...
@@ -151,7 +151,7 @@ class dircmp():
...
@@ -151,7 +151,7 @@ class dircmp():
def
cmpfiles
(
a
,
b
,
common
):
def
cmpfiles
(
a
,
b
,
common
):
res
=
([],
[],
[])
res
=
([],
[],
[])
for
x
in
common
:
for
x
in
common
:
res
[
cmp
(
path
.
cat
(
a
,
x
),
path
.
cat
(
b
,
x
))]
.
append
(
x
)
res
[
cmp
(
path
.
join
(
a
,
x
),
path
.
join
(
b
,
x
))]
.
append
(
x
)
return
res
return
res
...
...
Lib/glob.py
Dosyayı görüntüle @
784ca6c8
...
@@ -17,7 +17,7 @@ def glob(pathname):
...
@@ -17,7 +17,7 @@ def glob(pathname):
result
=
[]
result
=
[]
for
dirname
in
list
:
for
dirname
in
list
:
if
basename
or
path
.
isdir
(
dirname
):
if
basename
or
path
.
isdir
(
dirname
):
name
=
path
.
cat
(
dirname
,
basename
)
name
=
path
.
join
(
dirname
,
basename
)
if
path
.
exists
(
name
):
if
path
.
exists
(
name
):
result
.
append
(
name
)
result
.
append
(
name
)
else
:
else
:
...
@@ -25,7 +25,7 @@ def glob(pathname):
...
@@ -25,7 +25,7 @@ def glob(pathname):
for
dirname
in
list
:
for
dirname
in
list
:
sublist
=
glob1
(
dirname
,
basename
)
sublist
=
glob1
(
dirname
,
basename
)
for
name
in
sublist
:
for
name
in
sublist
:
result
.
append
(
path
.
cat
(
dirname
,
name
))
result
.
append
(
path
.
join
(
dirname
,
name
))
return
result
return
result
def
glob1
(
dirname
,
pattern
):
def
glob1
(
dirname
,
pattern
):
...
...
Lib/lib-stdwin/dirwin.py
Dosyayı görüntüle @
784ca6c8
...
@@ -11,7 +11,7 @@ import dircache
...
@@ -11,7 +11,7 @@ import dircache
def
action
(
w
,
string
,
i
,
detail
):
def
action
(
w
,
string
,
i
,
detail
):
(
h
,
v
),
clicks
,
button
,
mask
=
detail
(
h
,
v
),
clicks
,
button
,
mask
=
detail
if
clicks
=
2
:
if
clicks
=
2
:
name
=
path
.
cat
(
w
.
name
,
string
)
name
=
path
.
join
(
w
.
name
,
string
)
try
:
try
:
w2
=
anywin
.
open
(
name
)
w2
=
anywin
.
open
(
name
)
w2
.
parent
=
w
w2
.
parent
=
w
...
@@ -19,7 +19,7 @@ def action(w, string, i, detail):
...
@@ -19,7 +19,7 @@ def action(w, string, i, detail):
stdwin
.
message
(
'Can
\'
t open '
+
name
+
': '
+
why
[
1
])
stdwin
.
message
(
'Can
\'
t open '
+
name
+
': '
+
why
[
1
])
def
open
(
name
):
def
open
(
name
):
name
=
path
.
cat
(
name
,
''
)
name
=
path
.
join
(
name
,
''
)
list
=
dircache
.
opendir
(
name
)[:]
list
=
dircache
.
opendir
(
name
)[:]
list
.
sort
()
list
.
sort
()
dircache
.
annotate
(
name
,
list
)
dircache
.
annotate
(
name
,
list
)
...
...
Lib/shutil.py
Dosyayı görüntüle @
784ca6c8
...
@@ -52,8 +52,8 @@ def copytree(src, dst):
...
@@ -52,8 +52,8 @@ def copytree(src, dst):
dot_dotdot
=
'.'
,
'..'
dot_dotdot
=
'.'
,
'..'
for
name
in
names
:
for
name
in
names
:
if
name
not
in
dot_dotdot
:
if
name
not
in
dot_dotdot
:
srcname
=
path
.
cat
(
src
,
name
)
srcname
=
path
.
join
(
src
,
name
)
dstname
=
path
.
cat
(
dst
,
name
)
dstname
=
path
.
join
(
dst
,
name
)
#print 'Copying', srcname, 'to', dstname
#print 'Copying', srcname, 'to', dstname
try
:
try
:
#if path.islink(srcname):
#if path.islink(srcname):
...
...
Lib/stdwin/dirwin.py
Dosyayı görüntüle @
784ca6c8
...
@@ -11,7 +11,7 @@ import dircache
...
@@ -11,7 +11,7 @@ import dircache
def
action
(
w
,
string
,
i
,
detail
):
def
action
(
w
,
string
,
i
,
detail
):
(
h
,
v
),
clicks
,
button
,
mask
=
detail
(
h
,
v
),
clicks
,
button
,
mask
=
detail
if
clicks
=
2
:
if
clicks
=
2
:
name
=
path
.
cat
(
w
.
name
,
string
)
name
=
path
.
join
(
w
.
name
,
string
)
try
:
try
:
w2
=
anywin
.
open
(
name
)
w2
=
anywin
.
open
(
name
)
w2
.
parent
=
w
w2
.
parent
=
w
...
@@ -19,7 +19,7 @@ def action(w, string, i, detail):
...
@@ -19,7 +19,7 @@ def action(w, string, i, detail):
stdwin
.
message
(
'Can
\'
t open '
+
name
+
': '
+
why
[
1
])
stdwin
.
message
(
'Can
\'
t open '
+
name
+
': '
+
why
[
1
])
def
open
(
name
):
def
open
(
name
):
name
=
path
.
cat
(
name
,
''
)
name
=
path
.
join
(
name
,
''
)
list
=
dircache
.
opendir
(
name
)[:]
list
=
dircache
.
opendir
(
name
)[:]
list
.
sort
()
list
.
sort
()
dircache
.
annotate
(
name
,
list
)
dircache
.
annotate
(
name
,
list
)
...
...
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