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

Expand sigil_CURL in Mix task #36

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

kevinschweikert
Copy link
Collaborator

Closes #23

With mix curl_req.expand all the files in the lib directory are getting scanned for a sigil_CURL in their AST. I don't know what the preferred scope of files should be. This is currently a draft, because while it works with this code

def test do
  ~CURL(https://example.com)
end

it does not, because Sourceror.get_range(quoted) returns nil because somehow it cannot infer the range of the sigil when we do something like this:

def test do
  ~CURL(https://example.com) == true
end

If anybody has a solution, i would be very happy for some help or hints in the direction!

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.

Add mix task (or Ash Injector?) to replace ~CURL with %Req.Request{}
1 participant