2

Now, here is the format of the folder on my Linux machine:

/phd_simulations
    /ns-3
    /pybindgen
    /scenario

So ns-3, pybindgen, and scenario are all directories themselves...

Is this the correct workflow for git? There is no Linux desktop client (yet), so bear with me:

git init
git add .
git commit -m "First commit"
git remote add origin https://github.com/username/some-proj-name.git

git push

Right?

When I view the repository on GitHub.com, it only seems to be adding the folders themselves, NOT the contents.

I haven't used Git extensively yet (still learning), and I know I've done this successfully in the past, so I don't know what the deal is now.

jonrsharpe
  • 115,751
  • 26
  • 228
  • 437
Ginzorf
  • 769
  • 11
  • 19
  • What's the `git status`? Do you have a `.gitignore` file that might be interfering? Can you share the repo? – jonrsharpe Jun 17 '17 at 06:55

1 Answers1

0

It would add the folder only when those folders, locally on your computer, have a .git in them.
That would make them nested git repo, in which case, you should them as gray folder on GitHub.
See "Why github display gray folder to when I create a new repository?"

If you want just their files, remove (or move) the .git out of the way, and re-init your repo (add, commit, push --force).
Make sure you don't need the history of those nested repo first.

VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250