Add a method to determine console width
Summary:
I'm making arc tasks smarter about width-based printing for T1831 and want access to the console width to do so.
Getting it is kind of tricky without curses, which no one has. Get it to work reasonably.
Test Plan: Ran function, got correct output for my terminal.
Reviewers: btrahan, vrana
Reviewed By: btrahan
CC: aran
Maniphest Tasks: T1831
Differential Revision: https://secure.phabricator.com/D3567