Add session_info function
Merge pull request #526 from wch/print-sessioninfo

Add session_info function