James Boswell ( October 29 , 1740 - May 19 , 1795 ) was a Scottish lawyer and author . James Boswell , 9th Laird of Auchinleck ( 29 October 1740 â `` 19 May 1795 ) was a lawyer , diarist , and author born in Edinburgh , Scotland ; he is best known for his biography of Samuel Johnson .