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

Improve docs on how to enable vscode extension #1280

Open
JSBmanD opened this issue Jun 6, 2024 · 4 comments
Open

Improve docs on how to enable vscode extension #1280

JSBmanD opened this issue Jun 6, 2024 · 4 comments

Comments

@JSBmanD
Copy link

JSBmanD commented Jun 6, 2024

Environments

  • IDE Version: 1.87.2
  • Extension Version: v1.7.2
  • CSharpier Version: 0.28.2
    will NOT be the same as the extension version
  • Operating System: MacOS
  • .csharpierrc Settings: Where to find?
  • .editorconfig Settings: No for project

Log Output
No

Steps to reproduce

  1. Install extension
  2. Set csharpier as default formatter
image 3. Press hotkey to format document

Expected behavior
File formatted

Actual behavior
No logs, no format

dotnet csharpier . works when I call it in folder with files

@belav
Copy link
Owner

belav commented Jun 6, 2024

By no logs, do you mean that the output window for CSharpier is empty? Even without turning on debug logging it should contain ["INFO" - 8:54:38 AM] Initializing csharpier-vscode when it start up, which is when you first open a c# file I believe.

@JSBmanD
Copy link
Author

JSBmanD commented Jun 7, 2024

@belav i made it work by adding this to settings.json in project. But without it - it won't format my project for some reason. Can you add this to docs please? I needed to search in issues to find this solution

    "csharpier.enableDebugLogs": true,
    "[csharp]": {
        "editor.defaultFormatter": "csharpier.csharpier-vscode",
        "editor.formatOnSave": true,
    }

@belav
Copy link
Owner

belav commented Jun 7, 2024

My instance of vscode has an empty settings file, and I can right click, format with csharpier, and it works. It also initializes csharpier as expected. The doc already mentions setting it as the default formatter and neither debug logs or formatOnSave are required. I'm guessing there was something else going on with your IDE.

@JSBmanD
Copy link
Author

JSBmanD commented Jun 7, 2024

@belav maybe you need any logs or configs to see the problem? I can provide anything

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

No branches or pull requests

2 participants