dbcli / mssql-cli

A command-line client for SQL Server with auto-completion and syntax highlighting
BSD 3-Clause "New" or "Revised" License
1.35k stars 192 forks source link

Missing max filesize logic for 'mssqlcli.log' #481

Closed bjhulst closed 4 years ago

bjhulst commented 4 years ago

Hi,

I noticed the .config folder had a 2.3GB mssqlcli.log logfile stored. -rw-rw-r-- 1 ec2-user ec2-user 2374019714 May 26 03:00 mssqlcli.log

Could we add log filesize handling? For example not exceeded size 'X' or log file rotation of last 7 days with only 7 files in use?

Logic could be in mssqlcli/mssql_cli.py lines 234-240.

Regards, Bob

pensivebrian commented 4 years ago

@bjhulst - we fixed this in the latest version using the very mechanism you suggested, a rotation log file in PR https://github.com/dbcli/mssql-cli/pull/458.