1

I initiated git, then used following command to add all the files in commit.

git add * git commit -m "Starting project modifications" 

but still there is .htaccess file as untracked, I don't know why it was not added now I want to add it to my last commit. How can I add it without doing another commit.

1 Answer 1

1

As mentioned here:

https://www.atlassian.com/git/tutorials/rewriting-history/git-commit--amend

Following is the example:

# Edit hello.py and main.py git add hello.py git commit # Realize you forgot to add the changes from main.py git add main.py git commit --amend --no-edit 
Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.