M
M
Michael2022-03-20 19:41:21
git
Michael, 2022-03-20 19:41:21

git everything up-to-date error or something?

Hello everybody! I cloned the project, created a new project directory on the repository, redirected it to the new repository in git on the local machine, made changes to the project template and configuration files, and when the command is executed, it git push origin masterdisplays the message everything up-to-date.
PS I just started learning git, so maybe I'm describing something wrong or doing it
Step by step I performed the commands in git as follows:

git status
git add .
git commit -m "Комментарий"
git push origin master

I checked the path to the new repository with the command git remote -v, there are no questions to the path.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
S
Sergey Kuznetsov, 2022-03-21
@Bally

redirected to new repository

I don't understand this phrase. What command does this?
command executiongit push origin master

If the local repository is cloned from an external one, links between branches are automatically created.
You do not need to specify which repository ( origin ) and which branch ( master ) to push the current branch to.
Simple enoughgit push
gives the message everything up-to-date

It's not a mistake. The message says that everything is just fine and the current local branch is synchronized with the external branch to which you sent the commits.
But are you sure that the current branch is called master and not main ? Let's find out.
Show the output of the commands
git branch -vv
and Below the comment
git status
button , write clarifications there, and not a new answer to your question.

M
Michael, 2022-03-21
@Bally

Sergey Kuznetsov , when executing the command, git branch -vvdisplays the following information

* (no branch, rebasing master) 363fbce Изменения
  master                       16b4053 Добавление директории в репозиторий

While doinggit status
interactive rebase in progress; onto 90cda99
Last command done (1 command done):
   pick 592e37c Уроки ИМ ita-studio
Next commands to do (2 remaining commands):
   pick 728f28f Без изменений
   pick 16b4053 Добавление директории в репозиторий
  (use "git rebase --edit-todo" to view and edit)
You are currently editing a commit while rebasing branch 'master' on '90cda99'.
  (use "git commit --amend" to amend the current commit)
  (use "git rebase --continue" once you are satisfied with your changes)

nothing to commit, working tree clean


"redirected to a new repository"
I don't understand this phrase. What command does this?

In the .git/config file, I edited the url parameter in the [remote "origin"] section to indicate the new address.
The output of the command git remote -vshows the new address
origin  https://[email protected]/myname/yiishop.git (fetch)
origin  https://[email protected]/myname/yiishop.git (push)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question