Patent attributes
Implementations are described herein for building and/or applying a library of transformation templates to automate migration of source code. In various implementations, pre-migration and post-migration versions of source code that exist prior to and after migration of the source code may be analyzed. Based on the analysis, one or more transformations made to the pre-migration version of the source code to yield the post-migration version of the source code may be identified. A library of transformation templates that are applicable subsequently to automate migration of new source code may be built. In some implementations, for one or more of the transformations, a plurality of candidate transformation templates may be generated with different permutations of tokens being replaced with placeholders. One of the plurality of candidate transformation templates may be selected for inclusion in the library based on one or more criteria.