Skip to content

Commit 18e063f

Browse files
committed
export: set the pin direction on export according to config
Signed-off-by: Paul Osborne <[email protected]>
1 parent 306d772 commit 18e063f

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/export.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,10 @@ pub fn export(pin_config: &PinConfig, symlink_root: Option<&str>) -> Result<(),
2727
// create root directory if not exists
2828
try!(fs::create_dir_all(symroot));
2929

30+
// set the pin direction
31+
try!(pin_config.get_pin().set_direction(pin_config.direction.clone()));
32+
33+
// create symlink for each name
3034
for name in &pin_config.names {
3135
let mut dst = path::PathBuf::from(symroot);
3236
dst.push(name);

0 commit comments

Comments
 (0)