Skip to content

Latest commit

 

History

History
executable file
·
30 lines (21 loc) · 729 Bytes

File metadata and controls

executable file
·
30 lines (21 loc) · 729 Bytes

GIT - copy files from other branch

Overview

This is a HowTo for copying files from a <SOURCE-BRANCH> into the current one.

Prerequisite

  • git

Do it

checkout the <CURRENT-BRANCH> (where you wanna merge/copy the files to)

git checkout <CURRENT-BRANCH>

# e.g.
git checkout dev/something

copy the file from <SOURCE-BRANCH>

git checkout <SOURCE-BRANCH> <FILE1> <FILEn> <FOLDER1> <FOLDERn>

# e.g.
git checkout feature/awesome variables.tf

now the variables.tf-file in the dev/something-branch is exchanged with the one from feature/awesome-branch

Links