about summary refs log tree commit diff
path: root/overlays/scripts/choose/choosebin.in
blob: 7f8ea520c994edaf976f56ecbf5c90984bf7d113 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#! @execline@/bin/execlineb -S0

backtick -i entry_points {
  importas PATH PATH
  heredoc 0 $PATH
  tr : " "
}
importas -s -i -u entry_points entry_points

pipeline {
  redirfd -w 2 /dev/null
  find -L $entry_points -mindepth 1 -maxdepth 1 -executable -type f
}

pipeline { awk -F / "{print $NF}" }

@out@/bin/choose --prompt "$ " $@