mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-09-15 23:42:37 +03:00
Fix issue related to creating fdroidvcs file
This commit is contained in:
parent
b786c6de20
commit
23a950bd00
1 changed files with 3 additions and 1 deletions
|
@ -531,6 +531,7 @@ class vcs:
|
||||||
# automatically if either of those things changes.
|
# automatically if either of those things changes.
|
||||||
fdpath = os.path.join(self.local, '..',
|
fdpath = os.path.join(self.local, '..',
|
||||||
'.fdroidvcs-' + os.path.basename(self.local))
|
'.fdroidvcs-' + os.path.basename(self.local))
|
||||||
|
fdpath = os.path.normpath(fdpath)
|
||||||
cdata = self.repotype() + ' ' + self.remote
|
cdata = self.repotype() + ' ' + self.remote
|
||||||
writeback = True
|
writeback = True
|
||||||
deleterepo = False
|
deleterepo = False
|
||||||
|
@ -562,7 +563,8 @@ class vcs:
|
||||||
|
|
||||||
# If necessary, write the .fdroidvcs file.
|
# If necessary, write the .fdroidvcs file.
|
||||||
if writeback and not self.clone_failed:
|
if writeback and not self.clone_failed:
|
||||||
with open(fdpath, 'w') as f:
|
os.makedirs(os.path.dirname(fdpath), exist_ok=True)
|
||||||
|
with open(fdpath, 'w+') as f:
|
||||||
f.write(cdata)
|
f.write(cdata)
|
||||||
|
|
||||||
if exc is not None:
|
if exc is not None:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue