I'm trying to compare the output of running strings through GZIP on both Java, and the CLI gzip command. The outputs are not the same, and I've figure out why, but not sure how to get them to jive with each other.
I've read a number of questions on SO, have read the man pages for gzip, and the code for both GZIPOutputStream and DeflaterOutputStream. The default compression level for GZIPOutputStream (set through Deflator) is "-1", and there's little explanation as to what that means. Furthermore, gzip CLI only allows for values between 1 and 9, inclusive.
So is there a way I can change the compression settings in either Java or the gzip command to make them produce the same output?