Sha256: cbd685c8a6be6d27935b0265a52721378ac30299e60367543ced034ac072d5c0
Contents?: true
Size: 836 Bytes
Versions: 4
Compression:
Stored size: 836 Bytes
Contents
module Jets::Code::Copy class GitCopy < Base # interface method def create_temp_zip copy_to_code_temp # interface method # We leverage git archive for gitignore settings. Dir.chdir("#{build_root}/stage/code-temp") do if git_info.params[:git_dirty] quiet_sh "git add ." gitconfig quiet_sh "git commit -m 'add working tree files' > /dev/null || true" end quiet_sh "git archive -o #{build_root}/stage/code-temp.zip HEAD" end end # Copy project to stage/code-temp to use git add and archive # without affecting up the current git repo. # interface method. overriden by GitRsync def copy_to_code_temp FileUtils.mkdir_p("#{build_root}/stage") FileUtils.cp_r(Jets.root, "#{build_root}/stage/code-temp") end end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
jets-6.0.5 | lib/jets/code/copy/git_copy.rb |
jets-6.0.4 | lib/jets/code/copy/git_copy.rb |
jets-6.0.3 | lib/jets/code/copy/git_copy.rb |
jets-6.0.2 | lib/jets/code/copy/git_copy.rb |