Correction problème des peach
This commit is contained in:
parent
ec1c063802
commit
f8a35a9da3
4 changed files with 23 additions and 28 deletions
|
|
@ -35,10 +35,8 @@ fn -search [&sort=$false &type=exact @motive]{
|
|||
result = (put * | map:to-set)
|
||||
} else {
|
||||
peach [m]{
|
||||
var m = $m
|
||||
try {
|
||||
$f $m | peach [e]{
|
||||
var e = $e
|
||||
result[$e] = $nil
|
||||
}
|
||||
} except e { }
|
||||
|
|
@ -52,7 +50,6 @@ fn match-files [&sort=$false &type=prefix @motive]{ -search &sort=$sort &type=$t
|
|||
fn match-extensions [&sort=$false &type=deep-prefix motive @extensions]{
|
||||
result = [&]
|
||||
-search &type=$type $motive | peach [f]{
|
||||
var f = $f
|
||||
if (list:contains [e]{ str:has-suffix $f .$e } $extensions) {
|
||||
result[$f] = $nil
|
||||
}
|
||||
|
|
|
|||
|
|
@ -263,7 +263,6 @@ fn remove-duplicate [@argv]{
|
|||
fn premove-duplicate [@argv]{
|
||||
var done = [&]
|
||||
peach [v]{
|
||||
var v = $v
|
||||
done[$v] = $nil
|
||||
} (-p $@argv)
|
||||
keys $done
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue