Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/angular/33.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Angular 在现有Git repo上创建客户端/服务器文件夹结构_Angular_Git_Ionic4_Git Repo - Fatal编程技术网

Angular 在现有Git repo上创建客户端/服务器文件夹结构

Angular 在现有Git repo上创建客户端/服务器文件夹结构,angular,git,ionic4,git-repo,Angular,Git,Ionic4,Git Repo,我有一个git存储库,现在我需要向其中添加客户机和服务器文件夹。i、 e.将所有与Ionic相关的内容放入客户机文件夹,将与nodeJs相关的内容放入服务器文件夹。我是这样做的: 我已经有一个git上没有这个文件夹结构的git回购。i、 e.基本离子4应用程序的git回购 那么,我如何创建这种结构,并将其推到同一回购协议 我试过这个。但它给出了以下错误。我也试过拉git,但还没有运气 git push --set-upstream origin master To https://gi

我有一个git存储库,现在我需要向其中添加客户机和服务器文件夹。i、 e.将所有与Ionic相关的内容放入客户机文件夹,将与nodeJs相关的内容放入服务器文件夹。我是这样做的:

我已经有一个git上没有这个文件夹结构的git回购。i、 e.基本离子4应用程序的git回购 那么,我如何创建这种结构,并将其推到同一回购协议

我试过这个。但它给出了以下错误。我也试过拉git,但还没有运气

    git push --set-upstream origin master To https://gitlab.com/my-repo/client.git  ! [rejected]        
master -> master (non-fast-forward) error: failed to push some refs to 'https://gitlab.com/my-
repo/client.git' hint: Updates were rejected because the tip of your current branch is behind hint: its 
remote counterpart. Integrate the remote changes (e.g. hint: 'git pull ...') before pushing again. hint: 
See the 'Note about fast-forwards' in 'git push --help' for details.

注意:实际上,我的本地分支机构是最新的远程
master
。在创建上述文件夹结构之前,我已经这样做了。

当您执行git pull时,它会看到许多不相关的历史记录,并拒绝合并和从远程分支中提取代码,正如您在错误堆栈中看到的,请尝试使用:

git pull原始主机--允许不相关的历史记录

这将引入不相关的更改,之后可以通过手动解决编辑器中出现的冲突来合并更改。(左侧VS代码中的源代码管理。)

最后提交,并推送结果

希望这有帮助

From https://github.com/NishuGoel/ExampleStackOverFlow
 * branch            master     -> FETCH_HEAD
CONFLICT (add/add): Merge conflict in README.md
Auto-merging README.md
CONFLICT (add/add): Merge conflict in .gitignore
Auto-merging .gitignore
Automatic merge failed; fix conflicts and then commit the result.