Skip to content
Snippets Groups Projects
Commit d9008695 authored by nfontrod's avatar nfontrod
Browse files

src/init.rs: add mode parameter in init_and_hook function

parent 01242b85
Branches
No related tags found
No related merge requests found
...@@ -73,9 +73,10 @@ fn init_repository() { ...@@ -73,9 +73,10 @@ fn init_repository() {
/// # Arguments: /// # Arguments:
/// * `hooks`: a boolean indicating wether or not to create hooks /// * `hooks`: a boolean indicating wether or not to create hooks
/// * `compression`: The compression used automatically after each commit. This parameter is only used if hooks is true. /// * `compression`: The compression used automatically after each commit. This parameter is only used if hooks is true.
pub fn init_and_hook(hooks: bool, compression: &str) { /// * `mode`: The checkout mode used by gblk automatically after a git checkout: soft or hard.
pub fn init_and_hook(hooks: bool, compression: &str, mode: &str) {
init_repository(); init_repository();
if hooks { if hooks {
create_hooks::create_hooks(compression); create_hooks::create_hooks(compression, mode);
} }
} }
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment