read only the first line if more lines

This commit is contained in:
Nikos Kouremenos 2005-06-04 21:52:49 +00:00
parent 21f279a659
commit 942bcc75a5
1 changed files with 1 additions and 1 deletions

View File

@ -94,7 +94,7 @@ def get_os_info():
path_to_file = distro_info[distro_name]
if os.path.exists(path_to_file):
fd = open(path_to_file)
text = fd.read().strip()
text = fd.readline().strip() #get only first line
fd.close()
if path_to_file.endswith('version'):
# sourcemage_version has all the info we need