|
| 1 | +# Do not check code borrowed from ActiveSupport |
| 2 | +AllCops: |
| 3 | + Exclude: |
| 4 | + - 'lib/dbus/core_ext/**/*.rb' |
| 5 | + |
| 6 | +# https://github.com/SUSE/style-guides/blob/master/Ruby.md#strings |
| 7 | +Style/StringLiterals: |
| 8 | + EnforcedStyle: double_quotes |
| 9 | + |
| 10 | +Style/StringLiteralsInInterpolation: |
| 11 | + EnforcedStyle: double_quotes |
| 12 | + |
| 13 | +# https://github.com/SUSE/style-guides/blob/master/Ruby.md#arrays |
| 14 | +Style/WordArray: |
| 15 | + Enabled: false |
| 16 | + |
| 17 | +Style/IndentationConsistency: |
| 18 | + Exclude: |
| 19 | + # a conflict between markdown and ruby indentation |
| 20 | + - examples/doc/variants.rb |
| 21 | + |
| 22 | +# I am not ready to fix these |
| 23 | +Style/IfUnlessModifier: |
| 24 | + Enabled: false |
| 25 | + |
| 26 | +# I am not ready to fix these |
| 27 | +Style/WhileUntilModifier: |
| 28 | + Enabled: false |
| 29 | + |
| 30 | +# I am not ready to fix these |
| 31 | +Style/NegatedIf: |
| 32 | + Enabled: false |
| 33 | + |
| 34 | +Style/EmptyElse: |
| 35 | + EnforcedStyle: "nil" |
| 36 | + |
| 37 | +# Prefer readability over performance |
| 38 | +Performance/RedundantBlockCall: |
| 39 | + Enabled: false |
| 40 | + |
| 41 | +# Need to check whether API stays OK |
| 42 | +Lint/InheritException: |
| 43 | + Exclude: |
| 44 | + - 'lib/dbus.rb' |
| 45 | + - 'lib/dbus/auth.rb' |
| 46 | + - 'lib/dbus/bus.rb' |
| 47 | + - 'lib/dbus/introspect.rb' |
| 48 | + - 'lib/dbus/marshall.rb' |
| 49 | + - 'lib/dbus/matchrule.rb' |
| 50 | + - 'lib/dbus/message.rb' |
| 51 | + - 'lib/dbus/type.rb' |
| 52 | + |
| 53 | +# Offense count: 7 |
| 54 | +Lint/HandleExceptions: |
| 55 | + Exclude: |
| 56 | + - 'lib/dbus/marshall.rb' |
| 57 | + - 'lib/dbus/message_queue.rb' |
| 58 | + - 'lib/dbus/xml.rb' |
| 59 | + - 'spec/server_spec.rb' |
| 60 | + - 'spec/service_newapi.rb' |
| 61 | + |
| 62 | +# Offense count: 5 |
| 63 | +Lint/RescueException: |
| 64 | + Exclude: |
| 65 | + - 'examples/gdbus/gdbus' |
| 66 | + - 'examples/no-introspect/nm-test.rb' |
| 67 | + - 'lib/dbus/bus.rb' |
| 68 | + - 'lib/dbus/message_queue.rb' |
| 69 | + |
| 70 | +Style/PredicateName: |
| 71 | + NamePrefix: |
| 72 | + # has_ and have_ are allowed |
| 73 | + - is_ |
| 74 | + |
| 75 | +# Offense count: 1 |
| 76 | +Lint/Eval: |
| 77 | + Exclude: |
| 78 | + - 'examples/gdbus/gdbus' |
| 79 | + |
| 80 | +# Offense count: 1 |
| 81 | +Lint/NestedMethodDefinition: |
| 82 | + Exclude: |
| 83 | + - 'spec/main_loop_spec.rb' |
| 84 | + |
| 85 | +# Offense count: 34 |
| 86 | +Metrics/AbcSize: |
| 87 | + Max: 123 |
| 88 | + |
| 89 | +# Offense count: 2 |
| 90 | +Metrics/BlockNesting: |
| 91 | + Max: 4 |
| 92 | + |
| 93 | +# Offense count: 8 |
| 94 | +# Configuration parameters: CountComments. |
| 95 | +Metrics/ClassLength: |
| 96 | + Max: 297 |
| 97 | + |
| 98 | +# Offense count: 12 |
| 99 | +Metrics/CyclomaticComplexity: |
| 100 | + Max: 36 |
| 101 | + |
| 102 | +# Offense count: 62 |
| 103 | +# Configuration parameters: AllowHeredoc, AllowURI, URISchemes. |
| 104 | +# URISchemes: http, https |
| 105 | +Metrics/LineLength: |
| 106 | + Max: 118 |
| 107 | + |
| 108 | +# Offense count: 49 |
| 109 | +# Configuration parameters: CountComments. |
| 110 | +Metrics/MethodLength: |
| 111 | + Max: 96 |
| 112 | + |
| 113 | +# Offense count: 9 |
| 114 | +Metrics/PerceivedComplexity: |
| 115 | + Max: 27 |
| 116 | + |
| 117 | +# Offense count: 8 |
| 118 | +Style/ClassVars: |
| 119 | + Exclude: |
| 120 | + - 'lib/dbus/export.rb' |
| 121 | + - 'lib/dbus/message.rb' |
| 122 | + |
| 123 | +# Offense count: 16 |
| 124 | +Style/Documentation: |
| 125 | + Exclude: |
| 126 | + - 'spec/**/*' |
| 127 | + - 'test/**/*' |
| 128 | + - 'examples/gdbus/gdbus' |
| 129 | + - 'examples/service/service_newapi.rb' |
| 130 | + - 'lib/dbus/api_options.rb' |
| 131 | + - 'lib/dbus/error.rb' |
| 132 | + - 'lib/dbus/logger.rb' |
| 133 | + - 'lib/dbus/message.rb' |
| 134 | + - 'lib/dbus/message_queue.rb' |
| 135 | + - 'lib/dbus/type.rb' |
| 136 | + - 'lib/dbus/xml.rb' |
| 137 | + |
| 138 | +# Offense count: 1 |
| 139 | +Style/OptionalArguments: |
| 140 | + Exclude: |
| 141 | + - 'lib/dbus/proxy_object_interface.rb' |
0 commit comments