おとなしくしているみけです。
プロジェクトをGit管理下に置く
git cloneしてbuild.gradleを落としてきたのに、
gradle ideaした後に、
IDEAにGitの管理下に置くかと聞かれるのは嫌ですよね?
そんなときこそ、gradleがあるわけで、
build.gradleファイルに次のような記述を追加しておけば、
いちいちそんなこと聞かれなくなります。
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
idea.project.ipr { | |
withXml { provider -> | |
def map = provider.node.component.find { it.@name == 'VcsDirectoryMappings' }.mapping | |
map.@vcs = 'Git' | |
map.@directory = project.properties.projectDir | |
} | |
} |
0 件のコメント:
コメントを投稿