Atlassian Git API Diff Commits using Git notation -
i have been able "diff" 2 files using stash git api, however, each time have specify full hashes of commits, so:
rest/api/latest/projects/{project}/diff/{path file}?since={hash}&until={hash}
what this:
rest/api/latest/projects/{project}/diff/{path file}?since=head^^&until=head
to resemble:
git diff head^^ head {my_file}
(so diff between head , previous commits on file.)
the way have been able list of historical commits api using following docs:
https://stash.atlassian.com/rest/api/1.0/projects/jira/repos/jira/commits
which will: "the latest commits jira repository in jira project" not specific file.
from have been able find seems though api not support functionality.
i have been able solve this, firfox console. ui makes use of history drop down showing last 25 commits file following url:
rest/api/latest/projects/{project}/commits?path={path_to_file}&until=refs%2fheads%2fmaster&start=0&limit=25
Comments
Post a Comment