# File lib/rake.rb, line 2175 2175: def truncate(string, width) 2176: if string.length <= width 2177: string 2178: else 2179: ( string[0, width-3] || "" ) + "..." 2180: end 2181: end