{"id":187,"date":"2015-07-30T14:37:29","date_gmt":"2015-07-30T05:37:29","guid":{"rendered":"https:\/\/p-corporate-blog-cms.mmmcorp.co.jp\/blog\/2015\/07\/30\/rails_gem_recommend"},"modified":"2022-10-26T10:20:39","modified_gmt":"2022-10-26T01:20:39","slug":"rails_gem_recommend","status":"publish","type":"post","link":"https:\/\/p-corporate-blog-cms.mmmcorp.co.jp\/blog\/2015\/07\/30\/rails_gem_recommend\/","title":{"rendered":"Rails\u958b\u767a\u3067\u4f7f\u3063\u3066\u3044\u308b\u30aa\u30b9\u30b9\u30e1gem\u30925\u500b(-1\u500b)\u7d39\u4ecb\u3057\u307e\u3059"},"content":{"rendered":"

\u30cd\u30c3\u30c8\u4e0a\u306b\u306f\u3044\u308d\u3044\u308d\u3068\u4fbf\u5229\u306agem\u306e\u7d39\u4ecb\u30b5\u30a4\u30c8\u304c\u3042\u308b\u308f\u3051\u3060\u304c\u3001\u5f0a\u793e\u3067\u4f7f\u3063\u3066\u3044\u308bgem\u306b\u3064\u3044\u3066\u3082\u79c1\u306e\u72ec\u65ad\u3068\u504f\u898b\u3067\u9078\u3093\u3060\u304a\u3059\u3059\u3081gem\u30925\u500b(-1\u500b)\u3054\u7d39\u4ecb\u3057\u305f\u3044\u3002<\/p>\n

rubocop<\/a><\/h2>\n

\u30b3\u30fc\u30c9\u304cRuby Style Guide<\/a>\u306b\u6cbf\u3063\u3066\u3044\u308b\u304b\u3092\u30c1\u30a7\u30c3\u30af\u3059\u308bgem\u3002\u3053\u308c\u306f\u4ee5\u524d\u306e\u30d6\u30ed\u30b0\u8a18\u4e8b\u3067\u3082\u7d39\u4ecb\u3057\u305f\u3002
\n
RuboCop\u3092\u4f7f\u3063\u3066\u30b3\u30fc\u30c7\u30a3\u30f3\u30b0\u898f\u7d04\u306b\u6cbf\u3063\u305f\u30b3\u30fc\u30c9\u3092\u66f8\u304f<\/a><\/p>\n

RuboCop\u306e\u30c7\u30d5\u30a9\u30eb\u30c8\u8a2d\u5b9a\u306f\u304b\u306a\u308a\u53b3\u3057\u3044\u3002\u30e1\u30bd\u30c3\u30c9\u306f10\u884c\u4ee5\u5185<\/code>\u306a\u3093\u304b\u306f\u7d50\u69cb\u53b3\u3057\u3044\u3068\u601d\u3046\u3002\u30c1\u30a7\u30c3\u30af\u9805\u76ee\u3084\u8a2d\u5b9a\u306f\u5909\u66f4\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u308b\u306e\u3060\u304c\u3001\u3042\u3048\u3066\u53b3\u3057\u3044\u8a2d\u5b9a\u3067\u30c1\u30a7\u30c3\u30af\u3059\u308b\u3068\u3001\u30af\u30e9\u30b9\u5206\u5272\u3084\u30e1\u30bd\u30c3\u30c9\u5206\u5272\u306a\u3069\u3044\u308d\u3044\u308d\u3068\u8b70\u8ad6\u306e\u30cd\u30bf\u3092\u63d0\u4f9b\u3057\u3066\u304f\u308c\u3066\u9762\u767d\u3044\u3002
\n\u4f8b\u3048\u3070\u3001
\n\u300c\u3053\u3053\u306e\u30e1\u30bd\u30c3\u30c9\u304c10\u884c\u306b\u53ce\u307e\u3089\u306a\u3044\u3093\u3060\u3051\u3069\u3069\u3046\u3059\u308c\u3070\u3044\u3044\u304b\u306a\uff1f.rubocop\u3092\u66f8\u304d\u63db\u3048\u308b\u3063\u3066\u6700\u7d42\u624b\u6bb5\u4f7f\u3063\u3066\u3044\u3044\u3067\u3059\u304b\u30fb\u30fb\u30fb\uff1f\u300d
\n\u300c\u3046\u30fc\u3093\u3001Ruby\u306e\u30b7\u30f3\u30bf\u30c3\u30af\u30b9\u3092\u5909\u3048\u308c\u3070\u306a\u3093\u3068\u304b10\u884c\u306b\u53ce\u307e\u308b\u3051\u3069\u3001\u30e1\u30bd\u30c3\u30c9\u306e\u5f79\u5272\u81ea\u4f53\u3092\u8003\u3048\u306a\u304a\u3057\u3066\u3001\u3053\u308c\u3053\u308c\u3053\u3046\u3044\u3046\u30e1\u30bd\u30c3\u30c9\u306b\u5909\u3048\u305f\u307b\u3046\u304c\u3044\u3044\u3093\u3058\u3083\u306a\u3044\u304b\u306a\u3002\u300d
\n\u307f\u305f\u3044\u306a\u8b70\u8ad6\u304c\u304b\u308f\u3055\u308c\u308b\u3053\u3068\u306b\u306a\u308b\u3002<\/p>\n

pre-commit<\/a><\/h2>\n

\u30b3\u30df\u30c3\u30c8\u524d\u306b\u30d0\u30ea\u30c7\u30fc\u30b7\u30e7\u30f3\u3092\u304b\u3051\u3066\u3001\u901a\u3089\u306a\u304b\u3063\u305f\u3089\u30b3\u30df\u30c3\u30c8\u3092\u901a\u3089\u306a\u304f\u3059\u308b\u3002rubocop\u30c1\u30a7\u30c3\u30af\u3092\u5b9f\u884c\u3059\u308b\u3053\u3068\u3082\u53ef\u80fd\u3002\u4ee5\u524d\u3001vim\u306e\u4fdd\u5b58\u6642\u306brubocop\u30c1\u30a7\u30c3\u30af\u3092\u8d70\u3089\u305b\u308b\u65b9\u6cd5\u3092\u3054\u7d39\u4ecb\u3057\u305f\u304c\u3001\u3061\u3087\u3063\u3068\u4fdd\u5b58\u51e6\u7406\u304c\u91cd\u304f\u306a\u308b\u306e\u3067\u3001\u30b3\u30df\u30c3\u30c8\u6642\u306b\u30c1\u30a7\u30c3\u30af\u3092\u3059\u308b\u306e\u304c\u30d9\u30bf\u30fc\u304b\u3082\u3057\u308c\u306a\u3044\u3002\uff08rubocop\u306b\u6163\u308c\u308b\u307e\u3067\u306f\u4fdd\u5b58\u6642\u306b\u30c1\u30a7\u30c3\u30af\u3092\u3057\u305f\u307b\u3046\u304c\u3088\u3044\u3068\u304a\u3082\u3046\u3051\u308c\u3069\u3082\u3002\uff09<\/p>\n

\u53c2\u8003URL\uff1a
\n
git\u7528\u306epre-commit gem\u304c\u4fbf\u5229\u3059\u304e\u308b<\/a><\/p>\n

did_you_mean<\/a><\/h2>\n

\uff08\u8a00\u3044\u8a33\u3067\u3042\u308b\u304c\u3001\uff09\u79c1\u306f\u3082\u3068\u3082\u3068C\u3084Java\u306a\u3069\u306e\u30b3\u30f3\u30d1\u30a4\u30eb\u578b\u8a00\u8a9e\u3070\u304b\u308a\u3092\u66f8\u3044\u3066\u3044\u305f\u4eba\u9593\u306a\u306e\u3067\u3001Rails\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u304c\u30b9\u30da\u30eb\u30df\u30b9\u3067\u30a8\u30e9\u30fc\u306b\u306a\u3063\u3066\u3044\u308b\u5834\u5408\u306b\u539f\u56e0\u306b\u6c17\u3065\u304b\u306a\u3044\u3053\u3068\u304c\u3042\u308b\u3002\u3053\u306egem\u306f\u3001\u30a8\u30e9\u30fc\u6642\u306b\u3001\u3053\u3046\u3044\u3046\u30b9\u30da\u30eb\u30df\u30b9\u3058\u3083\u306a\u3044\u306e\uff1f\u3068\u30e1\u30c3\u30bb\u30fc\u30b8\u8868\u793a\u3057\u3066\u304f\u308c\u308b\u3082\u306e\u3067\u3042\u308b\u3002
\n\u4ee5\u4e0b\u304c\u516c\u5f0f\u30b5\u30a4\u30c8\u304b\u3089\u5f15\u7528\u3057\u305f\u30b5\u30f3\u30d7\u30eb\u3002\u672c\u6765user_signed_in?<\/code>\u3068\u66f8\u304f\u3079\u304d\u3068\u3053\u308d\u3001user_logged_in?<\/code>\u3068\u3044\u3046\u5b58\u5728\u3057\u306a\u3044\u30e1\u30bd\u30c3\u30c9\u540d\u3092\u66f8\u3044\u3066\u3057\u307e\u3063\u305f\u6642\u306b\u3001\u6b63\u3057\u3044\u30e1\u30bd\u30c3\u30c9\u540duser_signed_in?<\/code>\u3092\u30b5\u30b8\u30a7\u30b9\u30c8\u3057\u3066\u304f\u308c\u3066\u3044\u308b\u3002<\/p>\n

\"\"<\/p>\n

\u7cbe\u5ea6\u306f\u7d50\u69cb\u9ad8\u304f\u3001\u4f55\u5ea6\u3082\u52a9\u3051\u3089\u308c\u305f\u3053\u3068\u304c\u3042\u308b\u3002\u5165\u308c\u3066\u304a\u3044\u3066\u640d\u306f\u306a\u3044\u306e\u3067\u306f\u306a\u3044\u3060\u308d\u3046\u304b\u3002<\/p>\n

Airbrake<\/a><\/h2>\n

Airbrake\u3068\u3044\u3046Web\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u306e\u30a8\u30e9\u30fc\u3092\u76e3\u8996\u30fb\u901a\u77e5\u3059\u308b\u30b5\u30fc\u30d3\u30b9\u304c\u3042\u308b\u3002\u3053\u308c\u306f\u6709\u6599\u30b5\u30fc\u30d3\u30b9\u306a\u306e\u3060\u304c\u3001Errbit\u3068\u3044\u3046\u30af\u30ed\u30fc\u30f3\u304cOSS\u3067\u958b\u767a\u3055\u308c\u3066\u304a\u308a\u3001Errbit\u306e\u30b5\u30fc\u30d0\u3092\u7acb\u3066\u308b\u3053\u3068\u3067Airbrake\u3068\u540c\u69d8\u306e\u76e3\u8996\u3092\u5b9f\u73fe\u3059\u308b\u3053\u3068\u304c\u53ef\u80fd\u3067\u3042\u308b\u3002\u305d\u306e\u969b\u3001\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u304b\u3089Errbit\u3078\u306e\u30a8\u30e9\u30fc\u901a\u77e5\u306bairbrake gem\u3092\u4f7f\u7528\u3059\u308b\u3002
\n\u5f0a\u793e\u3067\u306fErrbit\u304b\u3089Slack\u306b\u30a8\u30e9\u30fc\u3092\u901a\u77e5\u3057\u3066\u3044\u308b\u3053\u3068\u304c\u591a\u3044\u3002
\nErrbit\u304a\u3088\u3073airbrake gem\u306e\u5c0e\u5165\u65b9\u6cd5\u306b\u3064\u3044\u3066\u306f\u3001\u591a\u304f\u306e\u30da\u30fc\u30b8\u304c\u5f15\u3063\u304b\u304b\u308b\u3002
\n\u4f8b\u3048\u3070\u3001
Errbit - Rails\u30a2\u30d7\u30ea\u306e\u672c\u756a\u30a8\u30e9\u30fc\u3092heroku\u3067\u7ba1\u7406\u3001\u30e1\u30fc\u30eb\u901a\u77e5\u3059\u308b\u3010\u7121\u6599\u67a0\u3011<\/a>\u3002
\n\u30cf\u30de\u308a\u3069\u3053\u308d\u306f\u307b\u3068\u3093\u3069\u306a\u3044\u3068\u601d\u3046\u3002<\/p>\n

Active Admin<\/a><\/h2>\n

\u304a\u3059\u3059\u3081gem\u3068\u3044\u3046\u8a18\u4e8b\u3060\u3051\u308c\u3069\u3082\u3001\u5b9f\u306f\u3053\u308c\u306f\u3042\u307e\u308a\u304a\u3059\u3059\u3081\u3057\u306a\u3044gem\u3002\u3002\u3002\u306a\u306e\u3067-1\u500b<\/code>\u3068\u66f8\u3044\u305f\u3002
\n\u4ee5\u524d\u3001
\n
ActiveAdmin\u3067\u3061\u3087\u3063\u3068\u4f7f\u3044\u52dd\u624b\u306e\u826f\u3044\u7ba1\u7406\u753b\u9762\u3092\u4f5c\u308bTips<\/a>
\n\u3068\u3044\u3046\u8a18\u4e8b\u3092\u66f8\u3044\u305f\u3002\u304a\u304b\u3052\u3055\u307e\u3067\u591a\u304f\u306e\u65b9\u306b\u898b\u3066\u3044\u305f\u3060\u3051\u3066\u3044\u308b\u306e\u3060\u304c\u3001\u6700\u8fd1\u611f\u3058\u3066\u3044\u308b\u306e\u306f\u3001\u6b63\u76f4Active Admin\u306f\u3042\u307e\u308a\u30aa\u30b9\u30b9\u30e1\u3067\u304d\u306a\u3044\u3068\u3044\u3046\u3053\u3068\u3067\u3042\u308b\u3002\u7279\u306b\u3001\u30c7\u30b6\u30a4\u30f3\u30b3\u30fc\u30c7\u30a3\u30f3\u30b0\u3092\u3061\u3083\u3061\u3083\u3063\u3068\u3057\u3066\u304f\u308c\u308b\u4eba\u304c\u3044\u308b\u5834\u5408\u3002\u305f\u3060\u3001\u30c7\u30b6\u30a4\u30f3\u306e\u30b3\u30fc\u30c0\u304c\u3044\u306a\u304f\u3066\u3082\u3001\u6700\u8fd1\u306fBootstrap\u306a\u3069\u3067\u3061\u3087\u3063\u3068\u3057\u305f\u30c7\u30b6\u30a4\u30f3\u306f\u30d7\u30ed\u30b0\u30e9\u30de\u3067\u3082\u7c21\u5358\u306b\u4f5c\u308c\u308b\u306e\u3067\u3001\u3084\u306f\u308aActive Admin\u306f\u30aa\u30b9\u30b9\u30e1\u3057\u306a\u3044\u3002\u7406\u7531\u306f\u3044\u308d\u3044\u308d\u3068\u3042\u308b\u306e\u3060\u304c\u3001\u3060\u3044\u305f\u3044\u4ee5\u4e0b\u306e\u7406\u7531\u3067\u3042\u308b\u3002<\/p>\n