Sha256: 445f5c7330f74a23280b8fe649a43f34c0a3636842ca222c22736130b7361af6
Contents?: true
Size: 478 Bytes
Versions: 50
Compression:
Stored size: 478 Bytes
Contents
# frozen_string_literal: true require 'ehbrs/self/observers/with_persistence' module Ehbrs module Self module Observers class UsedSpace < ::Ehbrs::Self::Observers::WithPersistence def path label end def calculate_value env = ::EacRubyUtils::Envs.local env.command('du', '-sb', path.to_s).pipe( env.command('cut', '-f', '-1') ).execute!.strip.to_i end end end end end
Version data entries
50 entries across 50 versions & 1 rubygems