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

Add optional ghc-path field in bios cradles #231

Merged
merged 5 commits into from
Aug 8, 2020

Conversation

pepeiborra
Copy link
Contributor

Fixes #215 to a simpler extent, in that the with-ghc field is of type String rather than IO String.

Cradle
{ cradleRootDir = wdir
, cradleOptsProg = CradleAction
{ actionName = Types.Bios
, runCradle = biosAction wdir biosCall biosDepsCall
, runGhcCmd = runGhcCmdOnPath wdir
, runGhcCmd = \args -> readProcessWithCwd wdir (fromMaybe "ghc" mbGhc) args ""
Copy link
Collaborator

Choose a reason for hiding this comment

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

Would it make sense to canonicalize the path if it is relative?

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 question, I'm not sure. The path is only ever used in this call to readProcess, so I think it probably doesn't matter much.

Copy link
Collaborator

@fendor fendor left a comment

Choose a reason for hiding this comment

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

Only one question, otherwise LGTM

README.md Outdated Show resolved Hide resolved
pepeiborra and others added 2 commits August 7, 2020 23:45
Co-authored-by: fendor <fendor@users.noreply.github.com>
@pepeiborra
Copy link
Contributor Author

Thanks for the quick review!

Once I fix the test failures, I'm very keen on a minor release incorporating this change as it will allow us to start using ghcide in some parts of our Haskelll codebase at work. Thanks again!

@fendor
Copy link
Collaborator

fendor commented Aug 8, 2020

The travis tests fail because you need to add the test files to the Extra-Source-Files section.

@fendor fendor merged commit cc8bced into haskell:master Aug 8, 2020
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.

How should bios cradles run ghc?
2 participants