How to add multiple projects into a Single repository in Bitbucket?

I am trying to add multiple projects into a single repository in Bitbucket, but after commiting when I pushed to the origin master it just added the empty folders. No subfolders and files have been added. I have followed below steps,

  1. From the main folder, git init
  2. git remote add origin gitrepository name
  3. git add --all
  4. git commit -m "initial commit"
  5. git push -u origin master

  • Bitbucket: fatal: HTTP request failed when trying to clone Git repo
  • Easiest way to rename git project configured on BitBucket
  • Git Subtree only one file or directory
  • Dealing with declined / rejected pull requests
  • Public key issue with command line in sourceTree (git )
  • I need to checkout single folder from a Bitbucket Git repo
  • Git merge two similar repositories into one (both added conflicts)
  • git difftool — how to skip a certain file?
  • git ignore exception not working as desired
  • Merging git branches when one has a revert that the other doesn't want
  • Ruby on Rails, Paperclip, Heroku, GitHub and AWS - securing keys
  • Local Git repository does not exist after sucessfull clone from cygwin bash
  • One Solution collect form web for “How to add multiple projects into a Single repository in Bitbucket?”

    That would happen if those project folders are themselves nested git repos.

    In that case, the content of those nested repos would be ignored: see “How to commit a git repo into a git repo (not submodule)”.

    You could try and “merge nested git repo into parent repo, retaining history”.

    Or you could declare those nested repo as submodule.
    (as in “Creating Git Submodules out of existing repository and reflecting parent changes to the child repository”)

    Git Baby is a git and github fan, let's start git clone.