Im currently working on a cms, and building an ajax / php remote updater script. The cms files are located on Github, and im using the API to get the file changes and source of those changes. As you can see here: https://api.github.com/repos/Plexis/Plexis/commits/116743cefde6765a4d4a8d0558bd17c4908dd586
Under "files" it lists all the changed files. The problem is, renamed / moved files. I cant seem to get a solid idea of how to get the original file so i can unlink it with php. If i try to get all the trees, that can take a ajax request per directoy... That's just too much. Anyone have an idea where i can get the source file's name and location before it was renamed / moved?
Might ask your changes as you're doing now, then for new files do not exist or could you try
https://api.github.com/repos/{user}/{repo}/commits?path={file.path}
for get her history. You can try with the hast too, the hash is the same event if the file has a diferent name
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With