scripts/install.py

branch
eric7-maintenance
changeset 10733
d96c69a235fc
parent 10694
f46c1e224e8a
parent 10716
11cdcc824469
child 10814
ba20efe10336
equal deleted inserted replaced
10695:161fdb080c76 10733:d96c69a235fc
217 @param src source file name 217 @param src source file name
218 @type str 218 @type str
219 @param dst destination file name 219 @param dst destination file name
220 @type str 220 @type str
221 """ 221 """
222 if os.path.exists(os.path.join("eric", "src", "eric7", "UI", "Info.py")): 222 if os.path.exists(os.path.join("eric", "src", "eric7", "__version__.py")):
223 # Installing from installer archive 223 # Installing from installer archive
224 from eric.src.eric7.UI.Info import Version # noqa: I101, I102 224 from eric.src.eric7.__version__ import Version # noqa: I101, I102
225 elif os.path.exists(os.path.join("src", "eric7", "UI", "Info.py")): 225 elif os.path.exists(os.path.join("src", "eric7", "__version__.py")):
226 # Installing from source tree 226 # Installing from source tree
227 from src.eric7.UI.Info import Version # noqa: I101, I102 227 from src.eric7.__version__ import Version # noqa: I101, I102
228 else: 228 else:
229 Version = "Unknown" 229 Version = "Unknown"
230 230
231 with open(src, "r", encoding="utf-8") as f: 231 with open(src, "r", encoding="utf-8") as f:
232 text = f.read() 232 text = f.read()
1229 shutilCopy( 1229 shutilCopy(
1230 os.path.join(eric7SourceDir, "pixmaps", "eric_2.icns"), 1230 os.path.join(eric7SourceDir, "pixmaps", "eric_2.icns"),
1231 os.path.join(directories["icns"], "eric.icns"), 1231 os.path.join(directories["icns"], "eric.icns"),
1232 ) 1232 )
1233 1233
1234 if os.path.exists(os.path.join("eric", "eric7", "UI", "Info.py")): 1234 if os.path.exists(os.path.join("eric", "eric7", "__version__.py")):
1235 # Installing from archive 1235 # Installing from archive
1236 from eric.eric7.UI.Info import CopyrightShort, Version # noqa: I101, I102 1236 from eric.eric7.__version__ import CopyrightShort, Version # noqa: I101, I102
1237 elif os.path.exists(os.path.join("eric7", "UI", "Info.py")): 1237 elif os.path.exists(os.path.join("eric7", "__version__.py")):
1238 # Installing from source tree 1238 # Installing from source tree
1239 from eric7.UI.Info import CopyrightShort, Version # noqa: I101 1239 from eric7.__version__ import CopyrightShort, Version # noqa: I101
1240 else: 1240 else:
1241 Version = "Unknown" 1241 Version = "Unknown"
1242 CopyrightShort = "(c) 2002 - 2024 Detlev Offenbach" 1242 CopyrightShort = "(c) 2002 - 2024 Detlev Offenbach"
1243 1243
1244 copyToFile( 1244 copyToFile(

eric ide

mercurial