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

CSharpier Requires dotnet tool restore #2868

Closed
Kurt-von-Laven opened this issue Aug 8, 2023 · 4 comments
Closed

CSharpier Requires dotnet tool restore #2868

Kurt-von-Laven opened this issue Aug 8, 2023 · 4 comments
Labels
bug Something isn't working O: stale 🤖 This issue or pull request is stale, it will be closed if there is no activity

Comments

@Kurt-von-Laven
Copy link
Collaborator

Describe the bug

Beginning in v7.0.0, CSharpier crashes if dotnet tool restore hasn't been run.

❌ Linted [CSHARP] files with [csharpier]: Found 1 error(s) - (0.62s)
--Error detail:
Run "dotnet tool restore" to make the "dotnet-csharpier" command available.

To Reproduce
Steps to reproduce the behavior:

  1. Run the dotnet flavor of MegaLinter in a project with C# files but no pre-commands.

Expected behavior
CSharpier runs successfully.

Additional context
I am splitting this issue out from #2578, which includes the workaround that can be added to .mega-linter.yaml:

CSHARP_CSHARPIER_PRE_COMMANDS:
  - command: dotnet tool restore
    continue_if_failed: false
    cwd: workspace
@Kurt-von-Laven Kurt-von-Laven added the bug Something isn't working label Aug 8, 2023
@nvuillam
Copy link
Member

nvuillam commented Aug 21, 2023

Good catch ! :)
Why do you think this dotnet tool restore is suddently necessary ?

@Kurt-von-Laven
Copy link
Collaborator Author

On mobile right now, but my first guess would be that there was some change to how we install CSharpier. I wonder if the fix could be as simple as running dotnet tool restore at the right place in the Dockerfiles.

@github-actions
Copy link
Contributor

This issue has been automatically marked as stale because it has not had recent activity.
It will be closed in 14 days if no further activity occurs.
Thank you for your contributions.

If you think this issue should stay open, please remove the O: stale 🤖 label or comment on the issue.

@github-actions github-actions bot added the O: stale 🤖 This issue or pull request is stale, it will be closed if there is no activity label Sep 22, 2023
@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Oct 6, 2023
@Kurt-von-Laven Kurt-von-Laven removed the O: stale 🤖 This issue or pull request is stale, it will be closed if there is no activity label Nov 9, 2023
@Kurt-von-Laven Kurt-von-Laven reopened this Nov 9, 2023
Copy link
Contributor

This issue has been automatically marked as stale because it has not had recent activity.
It will be closed in 14 days if no further activity occurs.
Thank you for your contributions.

If you think this issue should stay open, please remove the O: stale 🤖 label or comment on the issue.

@github-actions github-actions bot added the O: stale 🤖 This issue or pull request is stale, it will be closed if there is no activity label Dec 11, 2023
@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Dec 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working O: stale 🤖 This issue or pull request is stale, it will be closed if there is no activity
Projects
None yet
Development

No branches or pull requests

2 participants