Skip to content

Commit

Permalink
perl: Fix -dt: completion.
Browse files Browse the repository at this point in the history
  • Loading branch information
scop committed Jun 2, 2013
1 parent 18c28bb commit 97efc7c
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
4 changes: 4 additions & 0 deletions completions/perl
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,10 @@ _perl()
temp=$cur
prev=${temp:0:2}
cur=${temp:2}
if [[ $prev == -d && $cur == t* ]]; then
prev=-dt
cur=${cur:1}
fi
optPrefix=-P$prev
optSuffix=-S/
prefix=$prev
Expand Down
6 changes: 6 additions & 0 deletions test/lib/completions/perl.exp
Original file line number Diff line number Diff line change
Expand Up @@ -117,4 +117,10 @@ sync_after_int
assert_complete_any "perl -m-File::"
sync_after_int

assert_complete_any "perl -d:"
sync_after_int

assert_complete_any "perl -dt:"
sync_after_int

teardown

0 comments on commit 97efc7c

Please sign in to comment.