diff options
Diffstat (limited to 'code')
-rw-r--r-- | code/keys.rb | 2 | ||||
-rw-r--r-- | code/runcontext.rb | 4 |
2 files changed, 5 insertions, 1 deletions
diff --git a/code/keys.rb b/code/keys.rb index 583171e8..add38dbc 100644 --- a/code/keys.rb +++ b/code/keys.rb @@ -368,7 +368,7 @@ module Fm Action.run(RunContext.new(getfiles, nil, nil, 'editor')) end - when /^[ri](\d*)([adetw]*)[ri]$/ + when /^[ri](\d*)(?i:([adetw]*))[ri]$/ run_context = RunContext.new(getfiles, $1, $2) Action.run(run_context) diff --git a/code/runcontext.rb b/code/runcontext.rb index df9f3a81..f39e80d3 100644 --- a/code/runcontext.rb +++ b/code/runcontext.rb @@ -41,6 +41,10 @@ class RunContext @files = [files.dup] end self.flags = flags || '' + + if !@all and ( cf = Fm.currentfile ).is_a? Directory::Entry + @files = [cf] + end @files.reject! {|file| file.handler == nil or !file.exists? |