Class: Avmtrf1::Git::PushLarge::LfsCommit
- Inherits:
-
Object
- Object
- Avmtrf1::Git::PushLarge::LfsCommit
- Includes:
- EacRubyUtils::Console::Speaker, EacRubyUtils::SimpleCache
- Defined in:
- lib/avmtrf1/git/push_large/lfs_commit.rb,
lib/avmtrf1/git/push_large/lfs_commit/_cache.rb,
lib/avmtrf1/git/push_large/lfs_commit/_04_push.rb,
lib/avmtrf1/git/push_large/lfs_commit/_helpers.rb,
lib/avmtrf1/git/push_large/lfs_commit/_03_commit_changes.rb,
lib/avmtrf1/git/push_large/lfs_commit/_02_track_large_files.rb,
lib/avmtrf1/git/push_large/lfs_commit/_00_checkout_previous_revision.rb,
lib/avmtrf1/git/push_large/lfs_commit/_01_cherry_pick_source_revision.rb
Instance Attribute Summary collapse
-
#lfs_file_min_size ⇒ Object
readonly
Returns the value of attribute lfs_file_min_size.
-
#source_commit ⇒ Object
readonly
Returns the value of attribute source_commit.
-
#tracked_files ⇒ Object
readonly
Returns the value of attribute tracked_files.
Instance Method Summary collapse
- #commit ⇒ Avm::Git::Commit
- #fs_cache_uncached ⇒ Object
-
#initialize(source_commit, lfs_file_min_size) ⇒ LfsCommit
constructor
A new instance of LfsCommit.
- #push_ok? ⇒ Boolean
- #start_banner ⇒ Object
Constructor Details
#initialize(source_commit, lfs_file_min_size) ⇒ LfsCommit
Returns a new instance of LfsCommit.
16 17 18 19 20 21 |
# File 'lib/avmtrf1/git/push_large/lfs_commit.rb', line 16 def initialize(source_commit, lfs_file_min_size) @source_commit = source_commit @lfs_file_min_size = lfs_file_min_size @tracked_files = 0 @commit = nil end |
Instance Attribute Details
#lfs_file_min_size ⇒ Object (readonly)
Returns the value of attribute lfs_file_min_size.
14 15 16 |
# File 'lib/avmtrf1/git/push_large/lfs_commit.rb', line 14 def lfs_file_min_size @lfs_file_min_size end |
#source_commit ⇒ Object (readonly)
Returns the value of attribute source_commit.
14 15 16 |
# File 'lib/avmtrf1/git/push_large/lfs_commit.rb', line 14 def source_commit @source_commit end |
#tracked_files ⇒ Object (readonly)
Returns the value of attribute tracked_files.
14 15 16 |
# File 'lib/avmtrf1/git/push_large/lfs_commit.rb', line 14 def tracked_files @tracked_files end |
Instance Method Details
#commit ⇒ Avm::Git::Commit
8 9 10 11 |
# File 'lib/avmtrf1/git/push_large/lfs_commit/_03_commit_changes.rb', line 8 def commit commit_changes @commit end |
#fs_cache_uncached ⇒ Object
7 8 9 |
# File 'lib/avmtrf1/git/push_large/lfs_commit/_cache.rb', line 7 def fs_cache_uncached source_commit.fs_cache.child(lfs_file_min_size.present? ? lfs_file_min_size : 'nil') end |
#push_ok? ⇒ Boolean
23 24 25 |
# File 'lib/avmtrf1/git/push_large/lfs_commit.rb', line 23 def push_ok? push_ok end |
#start_banner ⇒ Object
27 28 29 30 |
# File 'lib/avmtrf1/git/push_large/lfs_commit.rb', line 27 def infov ' * LFS push', "revision: #{source_revision}" \ ", lfs_file_min_size: #{PushLarge.bytes_size(lfs_file_min_size)}" end |