如何解决git已经是最新的,没有任何理由
git初学者在这里,我一直在阅读有关此内容的信息,但仍然没有得到它,有人可以澄清一下。我的问题是我有git'master',这是这样的:
import { Component,ViewChildren,ElementRef,QueryList,AfterViewInit } from '@angular/core';
@Component({
selector: 'test-selector',templateUrl: './test.component.html'
})
export class TestComponent implements AfterViewInit {
@ViewChildren('myTemplateImage') imageList: QueryList<ElementRef>;
ngAfterViewInit() {
this.imageList.forEach((item) => {
item.nativeElement.parentNode.style.fontStyle = 'italic';
});
}
}
const list = [ 'h','e','l','o'];
list.map((currElement,index) => {
console.log("muutettu : " + index);
console.log("The curre: " + currElement);
console.log("\n");
return currElement; //equivalent to list[index]
});
我正在切换到分支主站'git checkout主站 '然后尝试将分支'kolmas'合并到该主分支中(git merge kolmas),我得到:已经是最新的。但是它不是最新的,它没有改变任何东西。
解决方法
- 使用
git checkout master; git diff kolmas
检查master
和kolmas
是否相同 - 如果它们相同并且您确实更改了代码,请使用
git status
检查它们是否已提交。 - 如果您可以使用
git status
,git checkout kolmas
查看更改,请分别使用git add
和git commit
进行提交。 - 提交更改后,您可以
git checkout master
并立即git merge
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。