Skip to content

Commit a019b8f

Browse files
authored
Merge pull request #2 from danharper/patch-1
Fix for React Native
2 parents d394ace + 77591b8 commit a019b8f

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

lib/fastlane/plugin/commit_android_version_bump/actions/commit_android_version_bump_action.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ def self.run(params)
1010
app_folder_name ||= params[:app_folder_name]
1111
UI.message("The commit_android_version_bump plugin is looking inside your project folder (#{app_folder_name})!")
1212

13-
build_folder_paths = Dir[File.expand_path(File.join('**/',app_folder_name))].reject { |file| file.include?('build/') }
13+
build_folder_paths = Dir[File.expand_path(File.join('**/', app_folder_name))].reject { |file| ['build/', 'node_modules/'].any? { |part| file.include? part } }
1414
# no build.gradle found: error
1515
UI.user_error!('Could not find a build folder in the current repository\'s working directory.') if build_folder_paths.count == 0
1616

@@ -27,7 +27,7 @@ def self.run(params)
2727
repo_pathname = Pathname.new(repo_path)
2828

2929

30-
build_file_paths = Dir[File.expand_path(File.join('**/',app_folder_name,'build.gradle'))]
30+
build_file_paths = Dir[File.expand_path(File.join('**/', app_folder_name, 'build.gradle'))].reject { |file| file.include? 'node_modules/' }
3131

3232
# no build.gradle found: error
3333
UI.user_error!('Could not find a build.gradle in the current repository\'s working directory.') if build_file_paths.count == 0

0 commit comments

Comments
 (0)