For this question, you need to commit the changes to one branch and then make those changes visible in the other branch. you don't need any changes on top of HEAD when changing branches.
You commit only the changed files by:
git commit [some files]
if you have a clean staging area then you can
git add [files] # add [files] to the staging area
git add [more files] # add [more files] to the staging area
git commit # commit [files] and [more files]
To make that commit available on both branches you could do
git stash # this will remove all changes from HEAD and save them somewhere else
git checkout <other-project> # change branches
git cherry-pick <commit-id> # pick a commit from ANY branch and apply it to the current
git checkout <first-project> # change to the other branch
git stash pop # restore all changes again