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

Prevent "current application does not depend on" compile warnings #13

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

pzingg
Copy link

@pzingg pzingg commented Feb 22, 2022

Uses the :extra_applications key in mix.exs
Exposes dependencies correctly in mix.exs to prevent these warnings:

warning: Earmark.as_html!/2 defined in application :earmark is used by the current application but the current application does not depend on :earmark. To fix this, you must do one of:

  1. If :earmark is part of Erlang/Elixir, you must include it under :extra_applications inside "def application" in your mix.exs

  2. If :earmark is a dependency, make sure it is listed under "def deps" in your mix.exs

  3. In case you don't want to add a requirement to :earmark, you may optionally skip this warning by adding [xref: [exclude: [Earmark]]] to your "def project" in mix.exs

  lib/phoenix_markdown/engine.ex:35: PhoenixMarkdown.Engine.compile/2

warning: HtmlEntities.decode/1 defined in application :html_entities is used by the current application but the current application does not depend on :html_entities. To fix this, you must do one of:

  1. If :html_entities is part of Erlang/Elixir, you must include it under :extra_applications inside "def application" in your mix.exs

  2. If :html_entities is a dependency, make sure it is listed under "def deps" in your mix.exs

  3. In case you don't want to add a requirement to :html_entities, you may optionally skip this warning by adding [xref: [exclude: [HtmlEntities]]] to your "def project" in mix.exs

  lib/phoenix_markdown/engine.ex:58: PhoenixMarkdown.Engine.do_restore_smart_tags/2

This will expose required deps, such as :earmark.
@altdsoy
Copy link

altdsoy commented Apr 25, 2022

Hello 👋🏼,
Is there a plan to merge that PR?

@altdsoy
Copy link

altdsoy commented May 9, 2022

Little up..
I hope OP @pzingg and author @boydm you are all good...

@thbar
Copy link

thbar commented Oct 16, 2023

I think we even got compilation failures at times (but not always), most likely linked to out upgrade to Elixir 1.15.

See:

It would be nice to merge this PR for continued use of the library on Elixir 1.15+!

@thbar
Copy link

thbar commented Oct 16, 2023

/cc @boydm @WalkerMills - unsure if this project is still maintained, and/or if you need extra people?

@jaimeiniesta
Copy link

Hi, there are new compilation warnings on Elixir 1.17:

==> phoenix_markdown
Compiling 2 files (.ex)
    warning: Regex.regex?/1 is deprecated. Use Kernel.is_struct(term, Regex) or pattern match on %Regex{} instead
    │
 82 │     if Regex.regex?(regex) do
    │              ~
    │
    └─ lib/phoenix_markdown/engine.ex:82:14: PhoenixMarkdown.Engine.only?/3
    └─ lib/phoenix_markdown/engine.ex:106:14: PhoenixMarkdown.Engine.except?/3

Copy link
Contributor

@WalkerMills WalkerMills left a comment

Choose a reason for hiding this comment

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

This change looks good but I don't have write access here. You get an approval from me fwiw 🤷

@WalkerMills
Copy link
Contributor

WalkerMills commented Dec 3, 2024

I actually don't use the fork I made of this project any more, I use this instead: https://gitlab.com/WalkerMills/phoenix_pandoc ETA: deleted the fork for clarity

It is similar, but I have some documents in latex and rst so I needed more than just markdown. I'm using it with Elixir 1.17

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.

5 participants