-
-
Notifications
You must be signed in to change notification settings - Fork 361
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
OS Specific Scripts #2848
Comments
That's IMO better solved with a Python wrapper script that builds the ignore flag value and calls pylint. The main reason being: to avoid scope-creep in PDM :) |
That makes sense. For context, I'm migrating from poetry and was using the |
I'm just a passer-by, @frostming gets the last word 😄 Maybe that's achievable through a PDM plugin by the way? |
IMHO your solution only solves a very specific need (what if I want Python version specific scripts?), and makes the configuration very complicated, which is not worth it. Good to learn |
I agree with all of the responses. You will have the best results creating a pylint wrapper script and tossing it in your [tool.pdm.scripts]
lint = "scripts/run-pylint.py [--args] DIR" |
Is your feature/enhancement proposal related to a problem? Please describe.
I have a Python project that runs on both Windows and Linux. I have a
lint
PDM script that runs pylint. The problem is that I need to ignore Windows-specific source files when running on Linux and ignore Linux-specific source files when running on Windows. I have what I consider a HACK that works:Describe the solution you'd like
I assume there's a better way to do what I need. If not, I think a new script type that selects the script to run based on the OS. Something like:
Looking at
TaskRunner.run_task
, I think we would add a newkind
that behaves something like:The text was updated successfully, but these errors were encountered: