lib/gloo/objs/system/file_handle.rb in gloo-3.3.0 vs lib/gloo/objs/system/file_handle.rb in gloo-3.4.0
- old
+ new
@@ -1,11 +1,10 @@
# Author:: Eric Crane (mailto:eric.crane@mac.com)
# Copyright:: Copyright (c) 2019 Eric Crane. All rights reserved.
#
# An object that points to a file in the system.
#
-require 'tty-pager'
module Gloo
module Objs
class FileHandle < Gloo::Core::Obj
@@ -56,11 +55,10 @@
# Show the contents of the file, paginated.
#
def msg_page
return unless value && File.file?( value )
- pager = TTY::Pager.new
- pager.page( path: value )
+ system "less #{value}"
end
#
# Show the contents of the file.
#