|
Code forensics
0.1
Generate historical information about code changes
|
repository processing algorithms More...
#include "repo_processing.hpp"#include "logging.hpp"#include "common.hpp"#include "git_interface.hpp"#include "repo_graph.hpp"#include <git2/patch.h>#include <boost/asio/thread_pool.hpp>#include <boost/asio/post.hpp>#include <algorithm>
Classes | |
| struct | FullCommitData |
Functions | |
| int | get_nesting (CR< Str > line) |
| FileId | stats_via_subprocess (git_oid commit_oid, walker_state *walker, File file, CR< Str > relpath) |
| FileId | stats_via_libgit (walker_state *state, git_oid commit_oid, const git_tree_entry *entry, CR< Str > relpath, File file) |
| FileId | exec_walker (git_oid commit_oid, walker_state *state, CommitId commit, const char *root, const git_tree_entry *entry) |
| CommitId | process_commit (git_oid commit_oid, walker_state *state) |
| void | file_tasks (Vec< SubTaskParams > &treewalk, walker_state *state, git_oid commit_oid, CommitId out_commit) |
| void | open_walker (git_oid &oid, walker_state &state) |
| void | for_each_commit (walker_state *state) |
| void | sample_blame_commits (walker_state *state, Vec< SubTaskParams > ¶ms) |
| Vec< CommitId > | launch_analysis (git_oid &oid, walker_state *state) |
repository processing algorithms
| FileId exec_walker | ( | git_oid | commit_oid, |
| walker_state * | state, | ||
| CommitId | commit, | ||
| const char * | root, | ||
| const git_tree_entry * | entry | ||
| ) |
| void file_tasks | ( | Vec< SubTaskParams > & | treewalk, |
| walker_state * | state, | ||
| git_oid | commit_oid, | ||
| CommitId | out_commit | ||
| ) |
| void for_each_commit | ( | walker_state * | state | ) |
| int get_nesting | ( | CR< Str > | line | ) |
| Vec<CommitId> launch_analysis | ( | git_oid & | oid, |
| walker_state * | state | ||
| ) |
| void open_walker | ( | git_oid & | oid, |
| walker_state & | state | ||
| ) |
| CommitId process_commit | ( | git_oid | commit_oid, |
| walker_state * | state | ||
| ) |
Implementaiton of the commit processing function. Walks files that were available in the repository at the time and process each file individually, filling data into the content store.
| void sample_blame_commits | ( | walker_state * | state, |
| Vec< SubTaskParams > & | params | ||
| ) |
| FileId stats_via_libgit | ( | walker_state * | state, |
| git_oid | commit_oid, | ||
| const git_tree_entry * | entry, | ||
| CR< Str > | relpath, | ||
| File | file | ||
| ) |
| FileId stats_via_subprocess | ( | git_oid | commit_oid, |
| walker_state * | walker, | ||
| File | file, | ||
| CR< Str > | relpath | ||
| ) |
Start git blame subprocess
Read it's standard output
Proces is started in the specified project directory
For now we are only looking into the authoring time