LEFT | RIGHT |
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 | 2 |
3 """ This module tries to retrieve as much platform-identifying data as | 3 """ This module tries to retrieve as much platform-identifying data as |
4 possible. It makes this information available via function APIs. | 4 possible. It makes this information available via function APIs. |
5 | 5 |
6 If called from the command line, it prints the platform | 6 If called from the command line, it prints the platform |
7 information concatenated as single string to stdout. The output | 7 information concatenated as single string to stdout. The output |
8 format is useable as part of a filename. | 8 format is useable as part of a filename. |
9 | 9 |
10 """ | 10 """ |
(...skipping 1523 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1534 return platform | 1534 return platform |
1535 | 1535 |
1536 ### Command line interface | 1536 ### Command line interface |
1537 | 1537 |
1538 if __name__ == '__main__': | 1538 if __name__ == '__main__': |
1539 # Default is to print the aliased verbose platform string | 1539 # Default is to print the aliased verbose platform string |
1540 terse = ('terse' in sys.argv or '--terse' in sys.argv) | 1540 terse = ('terse' in sys.argv or '--terse' in sys.argv) |
1541 aliased = (not 'nonaliased' in sys.argv and not '--nonaliased' in sys.argv) | 1541 aliased = (not 'nonaliased' in sys.argv and not '--nonaliased' in sys.argv) |
1542 print(platform(aliased,terse)) | 1542 print(platform(aliased,terse)) |
1543 sys.exit(0) | 1543 sys.exit(0) |
LEFT | RIGHT |