Copy File Between Git Branches

TIL that we can copy single file from another branch to current branch:

git checkout <branch-containing-the-file> </path/to/file>

In below screenshot we are copying a file from fiber-server-options to main branch:

Screenshot demonstrating copying file between git branches