fix: use generic AsRef<Path> for shell setup parameter
This commit is contained in:
parent
9628bf9b71
commit
1a20120c25
1 changed files with 2 additions and 2 deletions
|
|
@ -1,6 +1,6 @@
|
||||||
use std::path::Path;
|
use std::path::Path;
|
||||||
|
|
||||||
pub fn setup_shell(code_root: &Path) {
|
pub fn setup_shell<T: AsRef<Path>>(code_root: T) {
|
||||||
println!(
|
println!(
|
||||||
r#"
|
r#"
|
||||||
h() {{
|
h() {{
|
||||||
|
|
@ -10,6 +10,6 @@ h() {{
|
||||||
return $_h_ret
|
return $_h_ret
|
||||||
}}
|
}}
|
||||||
"#,
|
"#,
|
||||||
code_root.display()
|
code_root.as_ref().display()
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue