# DESCRIPTION
`bup features` reports information about the current bup installation,
-for example, whether command line editing is supported by `bup ftp`,
-or POSIX ACLs can be saved and restored.
+for example, which version of the Python interpreter is used, whether command
+line editing is supported by `bup ftp`, or POSIX ACLs can be saved and
+restored.
# EXAMPLES
$ bup features
bup 0.31~a7ff2d5b8c12b24b97858aad1251d28c18f8c1e1
source a7ff2d5b8c12b24b97858aad1251d28c18f8c1e1 2020-07-05 14:54:06 -0500
- Command line editing (e.g. bup ftp): yes
- Saving and restoring POSIX ACLs: yes
+ Python: 3.7.3
+ Command line editing (e.g. bup ftp): yes
+ Saving and restoring POSIX ACLs: yes
....
# SEE ALSO
# end of bup preamble
from __future__ import absolute_import, print_function
-import os.path, sys
+import os.path, sys, platform
sys.path[:0] = [os.path.dirname(os.path.realpath(__file__)) + '/..']
have_libacl = getattr(_helpers, 'read_acl', None)
have_xattr = metadata.xattr
+out.write(b' Python: %s\n' % platform.python_version().encode('ascii'))
show_support(out, have_readline, b'Command line editing (e.g. bup ftp)')
show_support(out, have_libacl, b'Saving and restoring POSIX ACLs')
show_support(out, have_xattr, b'Saving and restoring extended attributes (xattrs)')