-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Generate diff between two versions of the same code #33
Comments
Thanks for your feature request. I'm not sure, if it really fits to ChangeTrack. At least from an infrastructure perspective, ChangeTrack already provides quite some of the technical requirements to determine API changes between to revisions of a library: It can detect that a certain method has changed and it uses staticReflection which can provide you with the typing information of parameters. I could imagine to add a new command ( However you should be aware that there are some problems involved, from which ChangeTrack suffers in general. The biggest one is to track that a method was renamed or moved, for which I did not find a solution, yet. Do you already have code which performs some kind of automatic refactoring? Maybe https://github.com/QafooLabs/php-refactoring-browser could be a place to move that code? |
I think that command could be called Yes I have seen this refactoring tool. After talking to @beberlei I'm not sure however whether it is capable of performing these refactorings, nor if any other PHP solution is able to do so in a timely manner. |
Well, that of course depends on what you expect a "timely manner" to be. ;) But that should be discussed over at the refactoring browsers side.
|
I'm currently looking for a tool which is able to generate a machine-readable diff between two versions of some code and was pointed here by @beberlei. For example, if a parameter
$foo
was added to a method\Vendor\Foo::bar()
, the generated diff should mention all other relevant information (type hint, default value, position) that is needed to reproduce the change.My idea is to use this diff in another tool in order to automate refactorings. For example, if a dependent project uses
\Vendor\Foo::bar()
, I want to automatically perform the necessary changes (as far as possible) to make it compliant with the new version of that method.Do you think changetrack could be able to do this?
The text was updated successfully, but these errors were encountered: