Skip to content

Instantly share code, notes, and snippets.

@fakestarbaby
Last active January 27, 2016 12:31
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fakestarbaby/9e01b18828d8cdf168a0 to your computer and use it in GitHub Desktop.
Save fakestarbaby/9e01b18828d8cdf168a0 to your computer and use it in GitHub Desktop.
GitHub / GitLab で Unity 関連ファイルを折り畳んで楽々レビュー ref: http://qiita.com/fakestarbaby/items/c4f591062e5361b9b1a4
javascript:
String.prototype.endsWith = function(suffix) {
return this.indexOf(suffix, this.length - suffix.length) !== -1;
};
$('.file-header').each(function(index, value) {
var path = $(value).data('path');
var ignores = ['.unity', '.meta', '.anim', '.controller', '.prefab', '.asset', '.mat', '.tpsheet'];
for (i = 0; i < ignores.length; i++) {
if(path.endsWith(ignores[i])) {
$(value).parent().hide();
}
}
});
javascript:
String.prototype.endsWith = function(suffix) {
return this.indexOf(suffix, this.length - suffix.length) !== -1;
};
$('.file-header').each(function(index, value) {
$(value).parent().show();
});
javascript:
String.prototype.endsWith = function(suffix) {
return this.indexOf(suffix, this.length - suffix.length) !== -1;
};
$('.diff-file').each(function(index, value) {
var path = $(value).data('blob-diff-path');
var ignores = ['.unity', '.meta', '.anim', '.controller', '.prefab', '.asset', '.mat', '.tpsheet'];
for (i = 0; i < ignores.length; i++) {
if(path.endsWith(ignores[i] + '/diff')) {
$(value).hide();
}
}
});
javascript:
String.prototype.endsWith = function(suffix) {
return this.indexOf(suffix, this.length - suffix.length) !== -1;
};
$('.diff-file').each(function(index, value) {
$(value).show();
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment