Sistemata modifica in place con sed.
This commit is contained in:
parent
f2d0630c15
commit
ca1ab61e0c
@ -235,7 +235,7 @@ class Build(object):
|
||||
|
||||
# Changing desktop file
|
||||
subprocess.run(shlex.split("find . -iname startcenter.desktop -exec cp {} . \;"), cwd=self.appimagedir)
|
||||
subprocess.run(shlex.split("sed -i -e 's:^Name=.*$:Name=%s:' startcenter.desktop" % self.appname), cwd=self.appimagedir)
|
||||
subprocess.run(shlex.split("sed --in-place 's:^Name=.*$:Name=%s:' startcenter.desktop > startcenter.desktop" % self.appname), cwd=self.appimagedir)
|
||||
|
||||
subprocess.run(shlex.split("find . -name '*startcenter.png' -path '*hicolor*48x48*' -exec cp {} . \;"), cwd=self.appimagedir)
|
||||
|
||||
@ -351,7 +351,7 @@ class Build(object):
|
||||
os.unlink(zsyncfilename[arch])
|
||||
shutil.copyfile(self.zsyncfilename[arch], zsyncfilename[arch])
|
||||
# Editing the zsyncfile
|
||||
subprocess.run(shlex.split(f"sed -i'' -e 's/^Filename:.*$/Filename: {appimagefilename[arch]}/' {zsyncfilename[arch]}"))
|
||||
subprocess.run(shlex.split(f"sed --in-place 's/^Filename:.*$/Filename: {appimagefilename[arch]}/' {zsyncfilename[arch]}"))
|
||||
|
||||
|
||||
def __del__(self):
|
||||
|
Reference in New Issue
Block a user