The file_system types, Label & Path, are overengineered. It's more natural to use the Path and PathBuf types provided by the std library. This replaces any mention of Label with String and any use of the old Path with either std::path::Path or std::path::PathBuf, depending on what kind of ownwership is needed. Anywhere a "root" directory is needed `PathBuf::new()` is used, i.e. an empty `PathBuf`. Otherwise `Path::new` can used to pass directory, or in fact a &str can also be used since it implements AsRef<Path>. The `File` and `Directory` types also contain there relative paths, which can be retrieved while traversing the Tree. Note the special file name `"special/faux\\path"` requires the use of an escaping string construction, i.e. `r"special/faux\\path"`. Signed-off-by: Fintan Halpenny <fintan.halpenny@gmail.com> X-Clacks-Overhead: GNU Terry Pratchett
radicle-surf
A code surfing library for Git repositories 🏄♀️🏄♂️
Welcome to radicle-surf!
radicle-surf is a library to describe a Git repository as a file system. It
aims to provide an easy-to-use API to browse a repository via the concept of
files and directories for any given revision. It also allows the user to diff
any two different revisions.
One of the use cases would be to create a web GUI for interacting with a Git repository (thinking GitHub, GitLab or similar systems).
Contributing
To get started on contributing you can check out our developing guide, and also our LICENSE file.
The Community
Join our community disccussions at radicle.community!
Example
To a taste for the capabilities of radicle-surf we provide an example below, but we also
keep our documentation and doc-tests up to date.