Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8364695
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T12:29:01+00:00 2026-06-09T12:29:01+00:00

I have staged my files like this git add mydir git add mydir/myfile and

  • 0

I have staged my files like this

git add mydir
git add mydir/myfile

and then pushed them to my repo

git remote add origin https://github.com/usename/myrepo.git
git push origin master

When I look at git status -s it says my files have been added, but I cannot see them in my actual repository. Does anyone know whats going on here?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T12:29:02+00:00Added an answer on June 9, 2026 at 12:29 pm

    You have not “added” your files to the repository, only to the staging index.

    You need to git commit to get your changes from the staging index to the repository.

    git status shows you the status of the working tree and staging index. git log shows you the status of the history – in other words, git log will show you what’s been committed to the repository.

    As an example, see this git status output:

    
    git status               
    # On branch master
    # Changes to be committed:
    #   (use "git reset HEAD ..." to unstage)
    #
    #   modified:   Game.py
    #
    

    In this case, we can see that the changes to be committed involve Game.py. Note that these changes haven’t yet been added to the repository – they’re just staged, ready to be committed, as the git status says.

    The next step is to commit these changes we’ve prepared in the staging index and add them to the repository. git commit is the command to do this.

    This answer, as well as the linked Pro Git book, have some excellent reading which will help you understand the setup and steps in committing to a git repository.

    I cannot see them in my actual repository.

    What do you mean by “actual” repository? I am presuming you mean you can’t see a local commit, but there may be some confusion about the repositories you’re using.

    You’re using two repositories, one local and one remote. The remote repository is, in your case, on GitHub. You do your work locally, then git push to remote.

    First, local changes and commits

    So the steps to get your code changes into the local repository are as follows:

    1. Make changes in your working directory. This is most often writing some code.
    2. Build a commit by staging changes. This is done using git add.
    3. “Save” the commit you’ve built into the repository. This is done using git commit.

    These steps take place **locally*. None of these steps have any affect on your GitHub repository.

    Secondly, git push to the remote repository (in this case, your GitHub one).

    To get your code from local to remote repositories, git push is used.

    1. Check what remote repositories are known by your local repository: git remote -v.
    2. If the GitHub repository is not shown, you’ll need to add it: git remote add <NAME> <URL>.
    3. Because you didn’t git clone, the two repositories (local and remote) don’t have any commits in common. That’s ok; it just means git doesn’t automatically know where to push your changes, so you’ll have to specifiy: git push <NAME> master:master. That’ll push your local master branch to the <NAME> master branch.
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Oftentimes, when using git, I find myself in this situation: I have changes to
I like to use git add --patch (and more recently, git add -i) to
I have a question that's similar to How to undo 'git add' before commit?
We have a staged environment with 1 CMS and 3 Slave servers I want
My stage have 3 movieclip that is mc1,mc2 and mc3. each of them are
I'm new to git and I have a moderately large number of weekly tarballs
I have been searching for a solution to this for a while and have
I have a list of strangely encoded files: 02 - Charlie, Woody and You/Study
I've moved files from Project to Project/src . Git is under the impression that
So this is a quick question. I have now reached the stage of sending

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.