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

Allow dhall freeze to only freeze specific imports #663

Closed
ocharles opened this issue Oct 28, 2018 · 6 comments
Closed

Allow dhall freeze to only freeze specific imports #663

ocharles opened this issue Oct 28, 2018 · 6 comments
Assignees

Comments

@ocharles
Copy link
Member

I've found that while working I often want to freeze a subset of imports - in particular, imports from prelude.dhall-lang.org. What about adding --host to dhall freeze, as one solution?

@Gabriella439
Copy link
Collaborator

@ocharles: Yeah, that seems reasonable to me. I can't think of another way to accomplish the same thing within the existing set of features

@ocharles
Copy link
Member Author

Indeed. I wasn't sure if --host was the right interface though. Maybe --prefix which could take either a URL or file path. If it's a filepath, we canonicalise it and avoid freezing any imports with a similar prefix?

@joneshf
Copy link
Collaborator

joneshf commented Oct 29, 2018

An interesting option would be an --interactive flag that works similar to the -i/--interactive flag for the rm command: prompt before taking the action on each candidate. In this case, prompt for each import whether to freeze it or not.

@Gabriella439
Copy link
Collaborator

@joneshf: I think we should strive for things to be as non-interactive as possible, mainly because Dhall's target niche is large and complex configuration files, where individually prompting for each import might be prohibitive

@ocharles: Yeah, perhaps --prefix is more general. Let's go with that

@ocharles
Copy link
Member Author

Alright, I'll try and throw something together for --prefix

@Gabriella439
Copy link
Collaborator

I'll close this since I don't think anybody else has requested this recently and I'm not aware of anybody who plans to work on this. Feel free to reopen if somebody still needs this feature

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

Successfully merging a pull request may close this issue.

4 participants