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

Move "GetPathRelativeTo" from terragrunt and patcher here as a utility function #75

Open
ina-stoyanova opened this issue Oct 13, 2022 · 3 comments
Assignees
Labels
enhancement New feature or request

Comments

@ina-stoyanova
Copy link
Contributor

ina-stoyanova commented Oct 13, 2022

So far, we have had to copy and paste the GetPathRelativeTo function from terragrunt repo to the patcher/util repo package. We should instead have this command available here so we avoid duplication.

@ina-stoyanova ina-stoyanova added the enhancement New feature or request label Oct 13, 2022
@infraredgirl
Copy link
Contributor

infraredgirl commented Oct 19, 2022

This function already exists in go-commons: https://github.com/gruntwork-io/go-commons/blob/master/files/paths.go#L70.

However, it seems that a bug fix has been implemented in the function in Terragrunt, and hasn't been ported here.

Therefore the right course of action is:

  • Port the above bug fix from Terragrunt to go-commons
  • Remove the definition of GetPathRelativeTo from Terragrunt (and any other repos that currently define their own versions of it) and use the function from go-commons instead

@infraredgirl
Copy link
Contributor

Another bug in GetPathRelativeTo() was discovered and I just posted a fix in #78. After this is merged, I'll release another version of go-commons and ensure that all the repos that start to make use of GetPathRelativeTo() use this latest version.

@infraredgirl
Copy link
Contributor

Another bug in GetPathRelativeTo() was discovered and I just posted a fix in #78. After this is merged, I'll release another version of go-commons and ensure that all the repos that start to make use of GetPathRelativeTo() use this latest version.

This has been done.

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

No branches or pull requests

2 participants