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

Remove hardcoded dependency on deno.json #961

Closed
vwkd opened this issue Jan 3, 2023 · 2 comments · Fixed by #1208
Closed

Remove hardcoded dependency on deno.json #961

vwkd opened this issue Jan 3, 2023 · 2 comments · Fixed by #1208
Labels
feat New feature or request

Comments

@vwkd
Copy link
Contributor

vwkd commented Jan 3, 2023

Currently, fresh has a hardcoded dependency on ./deno.json for compiler options and throws and error if it doesn’t exist.

This prevents using fresh in a subdirectory, e.g. src/, of the repository, without maintaining duplicate deno.json files.

Workaround using a soft or hard link are not optimal. Also they introduce more issues, e.g. a soft link is currently not recognized by vscode_deno extension which prevents IntelliSense denoland/vscode_deno#784, while a hard link is not recognized by git which makes it impossible to synchronize it across different computers.

It would be great if the hardcoded dependency on ./deno.json could be avoided, made optional or configurable.

Seems to be introduced in #610 (review)

@lucacasonato
Copy link
Member

We should walk up the tree to find the deno.json that is in use.

@lucacasonato lucacasonato added the feat New feature or request label Jan 10, 2023
@iuioiua
Copy link
Contributor

iuioiua commented May 31, 2023

I think there are better alternatives, such as providing a CLI flag or taking advantage of Deno's inbuilt method of finding the deno.json, which would only be made possible by a new function in the runtime API (proposal here).

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

Successfully merging a pull request may close this issue.

3 participants