RE: Finding deprecated methods
Follow-on question: some deprecation warnings on say what the replacement for the method or class is. Java's QuickFix sometimes gets it right if a method is renamed, but punts when the parameters. Is there an easy way to update old usages that's faster than per-usage or per-deprecation? Is there a standard way we should be formatting our deprecation warnings to make it trivial for our users to upgrade their code base? On Jun 15, 2016 2:08 AM, "Uwe Schindler" <u...@thetaphi.de> wrote: > Hi, > > You can also download the JAR files of those releases and use a comparison > tool like http://siom79.github.io/japicmp/ to compare them. This tool can > be run using CLI and also prints changes in @Deprecated. > > The CLI syntax is here: http://siom79.github.io/japicmp/CliTool.html > > I always use "-m" (only show modified stuff) and "-o" and "-n" to specify > the old and new JAR file. After that you can grep on something like > DEPRECATED. > > Uwe > > - > Uwe Schindler > H.-H.-Meier-Allee 63, D-28213 Bremen > http://www.thetaphi.de > eMail: u...@thetaphi.de > > > -Original Message- > > From: Nick Burch [mailto:apa...@gagravarr.org] > > Sent: Wednesday, June 15, 2016 10:43 AM > > To: POI Developers List <dev@poi.apache.org> > > Subject: Re: Finding deprecated methods > > > > On Tue, 14 Jun 2016, Javen O'Neal wrote: > > > Is there a smarter way to find deprecated classes besides checking out > > > the code from 2 final releases ago and removing any deprecated code > that > > > still exists in trunk@HEAD? > > > > I'd probably attempt it with: > > * grep trunk for @deprecated with no date, with a -A 4 or similar, then > >grab the method name from that > > * grab a list of old versions from "svn ls ^/poi/tags/" > > * use "svn switch ^/poi/tags//" to quickly walk your tree back > through > >older versions > > * do the same greps, and spot where they vanish > > > > If that all sounds a bit hairy, let me know and I can try it later in the > > week! > > > > Nick > > > > - > > To unsubscribe, e-mail: dev-unsubscr...@poi.apache.org > > For additional commands, e-mail: dev-h...@poi.apache.org > > > - > To unsubscribe, e-mail: dev-unsubscr...@poi.apache.org > For additional commands, e-mail: dev-h...@poi.apache.org > >
RE: Finding deprecated methods
Hi, You can also download the JAR files of those releases and use a comparison tool like http://siom79.github.io/japicmp/ to compare them. This tool can be run using CLI and also prints changes in @Deprecated. The CLI syntax is here: http://siom79.github.io/japicmp/CliTool.html I always use "-m" (only show modified stuff) and "-o" and "-n" to specify the old and new JAR file. After that you can grep on something like DEPRECATED. Uwe - Uwe Schindler H.-H.-Meier-Allee 63, D-28213 Bremen http://www.thetaphi.de eMail: u...@thetaphi.de > -Original Message- > From: Nick Burch [mailto:apa...@gagravarr.org] > Sent: Wednesday, June 15, 2016 10:43 AM > To: POI Developers List <dev@poi.apache.org> > Subject: Re: Finding deprecated methods > > On Tue, 14 Jun 2016, Javen O'Neal wrote: > > Is there a smarter way to find deprecated classes besides checking out > > the code from 2 final releases ago and removing any deprecated code that > > still exists in trunk@HEAD? > > I'd probably attempt it with: > * grep trunk for @deprecated with no date, with a -A 4 or similar, then >grab the method name from that > * grab a list of old versions from "svn ls ^/poi/tags/" > * use "svn switch ^/poi/tags//" to quickly walk your tree back through >older versions > * do the same greps, and spot where they vanish > > If that all sounds a bit hairy, let me know and I can try it later in the > week! > > Nick > > - > To unsubscribe, e-mail: dev-unsubscr...@poi.apache.org > For additional commands, e-mail: dev-h...@poi.apache.org - To unsubscribe, e-mail: dev-unsubscr...@poi.apache.org For additional commands, e-mail: dev-h...@poi.apache.org
Re: Finding deprecated methods
On Tue, 14 Jun 2016, Javen O'Neal wrote: Is there a smarter way to find deprecated classes besides checking out the code from 2 final releases ago and removing any deprecated code that still exists in trunk@HEAD? I'd probably attempt it with: * grep trunk for @deprecated with no date, with a -A 4 or similar, then grab the method name from that * grab a list of old versions from "svn ls ^/poi/tags/" * use "svn switch ^/poi/tags//" to quickly walk your tree back through older versions * do the same greps, and spot where they vanish If that all sounds a bit hairy, let me know and I can try it later in the week! Nick - To unsubscribe, e-mail: dev-unsubscr...@poi.apache.org For additional commands, e-mail: dev-h...@poi.apache.org