Skip to content
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

Handle lockfiles in subdirectories #90

Merged
merged 5 commits into from Jul 21, 2021

Conversation

johnsyweb
Copy link
Contributor

Context

Some of our projects have separate bundles for deployment under ./deploy.

Change

This PR updates the runner to add a recursive flag, which when specified will attempt to perform a bundle update in any subdirectory containing a lockfile and annotate this change.

Copy link
Member

@orien orien left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! I have one question.

repo
)
end
GitCommandRunner.clone_repository("https://github.com/#{repo}", repo) unless Dir.exist?(repo)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TIL: the Rubocop default line length has been upped to 120.
rubocop/rubocop#7952

end
end
end
end

def self.run_unwapper_in_pwd(base_branch:, lock_files:)
def self.run_unwrappr_in_pwd(base_branch:, lock_files:, recursive:)
return unless any_lockfile_present?(lock_files)
Copy link
Member

@orien orien Jul 21, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I notice this check for lock-files. Does this mean the recursion won't run unless there's a lock file in the root of the git repository?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good spot. It does. I think that's OK.

Copy link
Member

@orien orien left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@johnsyweb johnsyweb merged commit be7c010 into main Jul 21, 2021
@johnsyweb johnsyweb deleted the paj/handle-lockfiles-in-subdirectories branch July 21, 2021 11:50
Copy link
Contributor

@petervandoros petervandoros left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Belated 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants