Skip to content

Getting the full abspath instead of the basename from a Blob #188

Answered by ishepard
daveaitel asked this question in Q&A
Discussion options

You must be logged in to vote

Oh mistery solved :)
See here: https://pydriller.readthedocs.io/en/latest/modifiedfile.html

  • filename: return only the filename (e.g., given a path-like-string such as “/Users/dspadini/pydriller/myfile.py” returns “myfile.py”)
  • new_path: new path of the file (can be None if the file is deleted)
  • old_path: old path of the file (can be None if the file is added)

What you want is the path (like in git, you have 2 paths, old and new, before and after the change, so you need to check both).

No worries, glad I could help!

Replies: 5 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by ishepard
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants