parent
02a42cdcbd
commit
ecd1977c05
@ -0,0 +1,12 @@ |
||||
#!/bin/sh |
||||
|
||||
# Print dirname of each relative pathname from stdin (one per line). |
||||
|
||||
# pathname dirname |
||||
# ---------------------- |
||||
# a/b/c.go a/b |
||||
# c.go . |
||||
exec sed \ |
||||
-e 's:^:./:' \ |
||||
-e 's:/[^/]*$::' \ |
||||
-e 's:^\./::' |
Loading…
Reference in new issue