-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merge toolkit-cleanup into develop #218
Merged
Merged
Changes from 156 commits
Commits
Show all changes
163 commits
Select commit
Hold shift + click to select a range
729ea28
Update CONTRIBUTING.md + rspec & yard default opts
AliSoftware 85656d6
[yard] ios_version_helper
AliSoftware 6aaa05d
Ruby convention for bool-returning methods
AliSoftware ed58b2d
small renames
AliSoftware 0091bb5
nit refactorings
AliSoftware 229a8d5
Fix @example tags in yard doc
AliSoftware 5d64c7b
Fix @throws -> @raise yard tags
AliSoftware 6fd7b24
yard nit fixes
AliSoftware 635249c
[yard] android_version_helper
AliSoftware 0da5978
[yard] ios_version_helper (nits)
AliSoftware 3296e3d
yardopts @env
AliSoftware 749e7a2
Improve @env documentation
AliSoftware 024d971
[yard] android_version_helper: constants
AliSoftware 05ddd9e
[yard] android_version_helper (finalize)
AliSoftware e52ec0d
Fix parameter names in screenshots_helpers
AliSoftware 4ccc052
formatting fix
AliSoftware 48b2067
module [Platform]::VersionHelper
AliSoftware 05ab6a6
module Ios::L10nHelper
AliSoftware f2ffe85
module [Platform]::GitHelper
AliSoftware aa30ec4
rename module Helpers -> Helper
AliSoftware 2bdd8d6
module Ios::ADCAppSizesHelper
AliSoftware 7a5fa31
android_localize_helper: split `module` tree
AliSoftware b9c2cad
android_localize_helper: move file
AliSoftware 3b280f9
Fix typos/formatting
AliSoftware 2bc0401
yardopts CRLF at EOF
AliSoftware 0813fe6
abort if PROJECT_ROOT_FOLDER undefined
AliSoftware 263ab3d
Remove constants @group, not really useful
AliSoftware 5d8271a
Merge pull request #198 from wordpress-mobile/yard-doc/step1
AliSoftware 57ca5ca
Merge pull request #199 from wordpress-mobile/yard-doc/step2
AliSoftware fe447cd
Merge branch 'toolkit-cleanup' into yard-doc/step3
AliSoftware 5891fe3
Merge pull request #200 from wordpress-mobile/yard-doc/step3
AliSoftware a65adac
git_checkout_and_pull[_release_branch_for]
AliSoftware 6e7ada6
branch_for_hotfix
AliSoftware f6d3535
tag_and_push
AliSoftware a4bf563
tag_build
AliSoftware 65e2275
final_tag
AliSoftware 9b1ba06
is_head_on_tag + has_final_tag_for
AliSoftware 15f622d
do_release_branch
AliSoftware 850cf6b
create_branch_for_hotfix -> cut_hotfix_branch
AliSoftware 2bd0cca
check_on_branch
AliSoftware ad48226
cut_[release|hotfix]_branch -> create_branch
AliSoftware ba703f7
Android::GitHelper::bump_version_*
AliSoftware 320bc4d
Ios::GitHelper.bump_version_*
AliSoftware 22a8cea
commit_version_bump YARD doc
AliSoftware 7347b54
delete_tags
AliSoftware 289369c
move update_metadata for consistency with iOS
AliSoftware 754d901
Ios::GitHelper.localize_project
AliSoftware 4c82a0d
update_metadata()
AliSoftware e68f6a1
YARD doc for remaining git_helper methods
AliSoftware e94273b
YARD doc for Git* modules
AliSoftware 237746d
Typo in YARD comment
AliSoftware e3264c7
Add todo in *_git_helper methods calling scripts
AliSoftware 34ed934
Merge pull request #206 from wordpress-mobile/cleanup/git-helpers
AliSoftware b5308c0
Configure rubocop rules and list of violations to fix
AliSoftware e876196
git ignore .idea (RubyMine files)
AliSoftware c01f0f7
Rename GHHelperHelper>GithubHelper and GHClient
AliSoftware 1c784b7
Fix rubocop offenses in github_helper.rb
AliSoftware 2d070a6
[rubocop] fix Layout/LeadingCommentSpace
AliSoftware 9cb90ca
[rubocop] fix Layout/SpaceAfterComma
AliSoftware 0652acb
[rubocop] fix Layout/SpaceAroundBlockParameters
AliSoftware 76de887
[rubocop] fix Layout/SpaceAroundKeyword
AliSoftware d3f121f
[rubocop] fix Layout/SpaceAroundOperators
AliSoftware 651a3d9
[rubocop] fix Layout/SpaceBeforeBlockBraces
AliSoftware 3524996
[rubocop] fix Layout/SpaceInLambdaLiteral
AliSoftware bb862da
[rubocop] fix Layout/SpaceInsideArrayLiteralBrackets
AliSoftware 3f63ddf
[rubocop] fix Layout/SpaceInsideBlockBraces
AliSoftware 2084482
[rubocop] fix Layout/SpaceInsideHashLiteralBraces
AliSoftware 3047fb8
[rubocop] fix Layout/SpaceInsideParens
AliSoftware f8f5e19
[rubocop] fix Layout/TrailingBlankLines
AliSoftware 5b7fe81
[rubocop] fix Layout/TrailingWhitespace
AliSoftware 4eb8cb5
[rubocop] fix Style/ColonMethodCall
AliSoftware e47e1fa
[rubocop] fix Layout/CommentIndentation
AliSoftware 1441c8e
[rubocop] fix Layout/MultilineMethodCallIndentation
AliSoftware acbf3f8
[rubocop] fix Layout/MultilineMethodCallBraceLayout
AliSoftware 764d779
[rubocop] Re-run --auto-gen-config
AliSoftware 622b99c
Fix gitignore comment
AliSoftware f6559c4
Move "Style/StringLiterals" to todo rules
AliSoftware d893cdf
Increase the checkout/fetch depth for Danger action
AliSoftware 89de96c
Merge pull request #207 from wordpress-mobile/rubocop-fixes/step-1
AliSoftware b1a256f
[rubocop] fix Style/StringLiterals
AliSoftware 15c2400
fix ext/drawText/extconf.rb path constructors
AliSoftware 427db8f
[rubocop] fix Layout/AlignArray
AliSoftware 3cdc4a8
[rubocop] fix Layout/CaseIndentation
AliSoftware 75ef6a6
[rubocop] fix Layout/IndentationConsistency
AliSoftware 53659f7
[rubocop] fix Layout/EmptyLines
AliSoftware 1ffb07a
[rubocop] fix Layout/AlignHash
AliSoftware 85af547
[rubocop] fix Layout/BlockAlignment
AliSoftware 66f3019
[rubocop] fix Layout/IndentationWidth
AliSoftware 4749cfa
[rubocop] fix Layout/IndentFirstArrayElement
AliSoftware b6eea80
[rubocop] fix Layout/IndentFirstHashElement
AliSoftware 8ef35af
[rubocop] fix Layout/IndentHeredoc
AliSoftware 71c72f6
[rubocop] fix Layout/EndAlignment
AliSoftware ba0c4fc
[rubocop] fix Layout/Tab
AliSoftware 2fe7b5a
[rubocop] fix Layout/EmptyLineAfterGuardClause
AliSoftware 21926b3
[rubocop] fix Layout/EmptyLinesAroundAccessModifier
AliSoftware 197566f
[rubocop] fix Layout/EmptyLinesAroundArguments
AliSoftware 785275c
[rubocop] fix Layout/EmptyLinesAroundBlockBody
AliSoftware 52df694
[rubocop] fix Layout/EmptyLinesAroundClassBody
AliSoftware 32af96f
[rubocop] fix Layout/EmptyLinesAroundExceptionHandlingKeywords
AliSoftware a4c7d53
[rubocop] fix Layout/EmptyLinesAroundMethodBody
AliSoftware 7f6558d
[rubocop] fix Layout/EmptyLinesAroundModuleBody
AliSoftware aad7637
[rubocop] fix Layout/ExtraSpacing
AliSoftware 7ec4c5e
[rubocop] fix Layout/LeadingBlankLines
AliSoftware a093c06
Merge pull request #210 from wordpress-mobile/cleanup/rubocop/step2
AliSoftware 9ae4e2d
Merge pull request #211 from wordpress-mobile/cleanup/rubocop/step3
AliSoftware 5d91148
[rubocop] fix Lint/AssignmentInCondition
AliSoftware 75a35ea
[rubocop] fix Lint/DeprecatedClassMethods
AliSoftware 9972c26
[rubocop] fix Lint/StringConversionInInterpolation
AliSoftware 19ac40b
[rubocop] fix Lint/UnusedBlockArgument
AliSoftware 86f4f0b
[rubocop] disable Lint/UnusedMethodArgument (manual)
AliSoftware c748791
[rubocop] fix Lint/ParenthesesAsGroupedExpression (manual)
AliSoftware 3b81d20
[rubocop] fix Lint/ShadowingOuterLocalVariable (manual)
AliSoftware 9a604f2
[rubocop] fix Style/AndOr
AliSoftware 3c24919
[rubocop] fix Style/BarePercentLiterals
AliSoftware 604b017
[rubocop] fix Style/BlockDelimiters
AliSoftware 70c7b6e
[rubocop] fix Style/BracesAroundHashParameters
AliSoftware 75c9583
[rubocop] fix Style/ClassAndModuleChildren
AliSoftware c3efa66
Merge pull request #213 from wordpress-mobile/cleanup/rubocop/step4
AliSoftware a9d818d
[rubocop] fix Style/ClassCheck
AliSoftware 3bb7aed
[rubocop] fix Style/ConditionalAssignment
AliSoftware bfb40c9
[rubocop] fix Style/DefWithParentheses
AliSoftware bda5e57
[rubocop] fix Style/EmptyLiteral
AliSoftware 2a93320
[rubocop] configure Style/EmptyMethod
AliSoftware 9c77eca
[rubocop] fix Style/Encoding
AliSoftware 9f2c690
[rubocop] fix Style/ExpandPathArguments
AliSoftware 4a56484
[rubocop] fix Style/FormatString
AliSoftware 191e9e5
[rubocop] disable Style/FrozenStringLiteralComment
AliSoftware 5830fc7
[rubocop] fix Style/HashSyntax
AliSoftware a882be7
[rubocop] fix Style/IfUnlessModifier
AliSoftware 7fe4b1a
[rubocop] fix Style/InverseMethods
AliSoftware 4cb320a
[rubocop] fix Style/ParenthesesAroundCondition
AliSoftware 0250763
[rubocop] fix Style/MultilineIfThen
AliSoftware 3750c49
[rubocop] fix Style/NegatedIf
AliSoftware 0bc24dc
[rubocop] fix Style/NegatedUnless
AliSoftware 79995c3
[rubocop] fix Style/NilComparison
AliSoftware 6de7f59
[rubocop] fix Style/NonNilCheck (safe-auto-correct)
AliSoftware b7691b6
[rubocop] fix Style/NonNilCheck (manual fixes) ⚠️
AliSoftware f84285d
[rubocop] ⚠️ Manual fix of Metrics/AbcSize
AliSoftware 27fd9d1
[rubocop] fix Style/Not
AliSoftware 7976a90
[rubocop] fix Style/NumericLiteralPrefix
AliSoftware 9d47d7d
[rubocop] fix Style/PercentLiteralDelimiters
AliSoftware 461eb41
[rubocop] fix Style/RegexpLiteral
AliSoftware 16a9ecb
[rubocop] fix Style/Semicolon
AliSoftware dc044c3
[rubocop] fix Style/StringLiteralsInInterpolation
AliSoftware 9c5080d
[rubocop] fix Style/TrailingCommaInArguments
AliSoftware 3b6252c
[rubocop] fix Style/TrailingCommaInArrayLiteral
AliSoftware 17b1e76
[rubocop] fix Style/TrailingCommaInHashLiteral
AliSoftware da50f50
Merge branch 'cleanup/rubocop/step5' into merge-develop-into-cleanup
AliSoftware 4b68f3b
[rubocop] auto-correct new code from develop
AliSoftware c89d683
[rubocop] fix Metrics/LineLength (in new code from develop)
AliSoftware fe48a8c
[rubocop] Regen todo config for code from develop
AliSoftware 4492cc7
Add comment about octal notation for chmod-like flags
AliSoftware f6499f7
[rubocop] fix Style/TrailingCommaInArrayLiteral
AliSoftware fd8d9bd
build_entries doesn't need the whole config Hash
AliSoftware 6fffd84
Merge pull request #214 from wordpress-mobile/cleanup/rubocop/step5
AliSoftware 74a3982
Merge pull request #215 from wordpress-mobile/merge-develop-into-cleanup
AliSoftware e9cbc69
[rubocop] disable Style/AsciiComments rule
AliSoftware d096f63
[rubocop] fix Style/Lambda
AliSoftware 83a4d0d
[rubocop] fix Style/UnneededInterpolation
AliSoftware ee543ca
[ruboco] run safe-auto-correct + auto-gen-config after rebase
AliSoftware 98af7e7
Remove some extra .to_s calls
AliSoftware 70fb5d5
Provide some rationale for custom Style rules
AliSoftware 228044e
Merge pull request #217 from wordpress-mobile/cleanup/rubocop/6
AliSoftware File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
--color | ||
--format documentation |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,61 @@ | ||
inherit_from: .rubocop_todo.yml | ||
|
||
require: | ||
- rubocop-rspec | ||
|
||
Metrics/BlockLength: | ||
########## Lint / CodeStyle | ||
|
||
# This gem is included as part of the `Pluginfile`, which is `required` separately, | ||
# so makes it hard to keep it ordered with the rest of the gems | ||
Gemspec/OrderedDependencies: | ||
Exclude: | ||
- 'spec/**/*.rb' | ||
- 'fastlane-plugin-wpmreleasetoolkit.gemspec' | ||
|
||
# Especially for actions and methods like `self.run(params)` it's common to have the argument unused; but that | ||
# comes with the parent class API / contract, so we feel it more readable to avoid the _ unused prefix for those. | ||
Lint/UnusedMethodArgument: | ||
Enabled: false | ||
|
||
Style/EmptyMethod: | ||
EnforcedStyle: expanded | ||
|
||
Style/TrailingCommaInArrayLiteral: | ||
EnforcedStyleForMultiline: consistent_comma | ||
|
||
# Enabling the 'frozen_string_literal: true' comment is nice but should be done with extra care | ||
# because enabling it on code that accidentally mutates string literals will crash at runtime | ||
# (e.g. `name = 'Hello'` then later `name << ' world'` will crash if the comment is enabled) | ||
# So we might enable it at some point, be we will need very careful review that this doesn't break everything. | ||
Style/FrozenStringLiteralComment: | ||
Enabled: false | ||
|
||
########## Metrics / Max Lengths Rules | ||
|
||
Metrics/LineLength: | ||
Max: 300 | ||
|
||
Metrics/AbcSize: | ||
Max: 140 | ||
|
||
Metrics/BlockLength: | ||
Max: 80 | ||
|
||
Metrics/ClassLength: | ||
Max: 300 | ||
|
||
Metrics/MethodLength: | ||
Max: 100 | ||
|
||
Metrics/ModuleLength: | ||
Max: 300 | ||
|
||
Metrics/ParameterLists: | ||
Max: 10 | ||
|
||
########## Metrics / Complexity | ||
|
||
Metrics/CyclomaticComplexity: | ||
Max: 20 | ||
|
||
Metrics/PerceivedComplexity: | ||
Max: 20 |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes for 🎨 !
I think I came across a study (or maybe just an anecdote 🤔 ) on the value of having red for failed and green for passing tests from a psychological point of view. Something like green is calmer so you'll want to get to green fast. Maybe.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The only issue with this, especially with a distributed company like us, is that colors might have different meanings depending on cultures; especially, in China, red is positive and green is negative (*), so the opposite meaning of what western culture is used to. I wonder if rspec and similar tools take the locale into account and switch those accordingly, but I doubt it. AFAIK we don't have anyone working on this codebase living in China, but still a good anecdote to know about.
(*) that's why, for example, in Apple's Stocks app, if you have your device's locale and region set to China, the colors used for positive vs negative fluctuations are switched compared to a device set in any other region.