Git忽略离子项目 [英] Git ignore for ionic project

查看:118
本文介绍了Git忽略离子项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我对于存储库的主题有点新的应用程序,当我做一个提交无尽文件上传时,我发现很难识别项目中的变化,这就是为什么我想要在这里寻求帮助,如果我可以指导你忽略文件,如果一个文件默认存在占用和在哪里,因为大部分工作是在www文件夹中完成的。对不起,如果问题是非常基本的,但我将远远解决这个问题。

解决方案

这里的问题是,如果您已经添加所有这些文件,一旦你放置 .gitignore ,它将不会按你的想法工作。你需要把 .gitignore 放在你项目的最开始。

所以,我的建议是:make another项目在Git中,只需再次上传您的项目并创建 .gitignore 文件。我是根据我自己的经验告诉你的。



你应该把 .gitignore

  node_modules 
.tmp
.sass-cache
** / bower_components或有时它是lib / **
平台
插件
* .swp
* .swo
* .log
* .DS_Store

为了创建这个文件,你可以从Git或者你的终端完成它:


  1. 在终端中,导航至您的Git存储库的位置。 c $ c>创建一个 .gitignore 文件。


I'm somewhat new applications with ionic and very new to the subject of the repositories, when I do a commit endless files are uploaded that I find it very difficult to identify what are the changes in the project, that's why I wanted ask for help here, if I can guide you ignore files, if a file exists by default to occupy and where, since most of the work is done in the www folder. Sorry if the question is very basic but I would serve far solve this problem.

解决方案

The problem here is that if you already add all those files, once you put the .gitignore it will not work as you want. You need to put the .gitignore at the very beginning of your project.

So, my advise: make another project in Git, just upload your project again and create the .gitignore file. I am telling you this based on my own experience.

The basics of what you should put in that .gitignore

node_modules
.tmp
.sass-cache
**/bower_components or sometimes it is lib/**
platforms
plugins
*.swp
*.swo
*.log
*.DS_Store

in order to create this file, you can do it from Git, or from your terminal:

  1. In Terminal, navigate to the location of your Git repository.
  2. Enter $ touch .gitignore to create a .gitignore file.

这篇关于Git忽略离子项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆