Python Forum
Is there a better way of formatting os.uname() output?
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Is there a better way of formatting os.uname() output?
#7
(Aug-27-2021, 09:35 PM)bowlofred Wrote: I don't think the comprehension is necessary. You can iterate directly over os.uname().

self.info = "\n\n".join(os.uname()) + "\n\n"

Even better, thank you! ^^
Reply


Messages In This Thread
RE: Is there a better way of formatting os.uname() output? - by CodeWolf - Aug-27-2021, 11:41 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Formatting float number output barryjo 2 1,014 May-04-2023, 02:04 PM
Last Post: barryjo
  Formatting to output file Mark17 2 1,388 Jan-13-2022, 09:06 PM
Last Post: BashBedlam
  Is there a better way to print uname information? EkaCaesium 4 3,908 Apr-26-2021, 12:51 PM
Last Post: EkaCaesium
  Output formatting Steffenwolt 0 2,232 Jan-18-2018, 03:47 PM
Last Post: Steffenwolt

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020