PowerShell / PowerShell/PSScriptAnalyzer
[formatter] Comment to let formatter ignore contents
Dieses Issue hat noch niemand übernommen.
- Vorherrschende Sprache
- C#
- Sterne
- 2.2k
- Forks
- 414
- Ø Merge
- 13 Std. 1 Min.
- Gemergte PRs (30 T.)
- 2
Beschreibung
Summary of the new feature
A common feature of formatter is to ignore formatting for rest of lines/range of lines with special comments.
I propose this feature because formatting rules in pssa are rather bold, you can't get a finer control on the style, so ignoring certain part can save my code from being messed up.
# ignore a range of lines
# pssa: ignore format start
echo foo
echo bar
# pssa: ignore format end
# ignore the rest of lines
# pssa: ignore format
echo foo
Proposed technical implementation details (optional)
What is the latest version of PSScriptAnalyzer at the point of writing
I don't know, I use powershell-editor-services
Beitragsleitfaden
Erste Schritte
- Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
- Forke das Repository und arbeite in einem Branch.
- Öffne einen Pull Request, der die Issue-Nummer nennt.
Rechercherichtung
In der Issue werden keine Dateien, Tests oder Einstiegspunkte des Formatierers genannt. Beginne damit, die Implementierung des PSScriptAnalyzer-Formatierers und dessen Umgang mit Kommentaren zu finden, und sieh dir anschließend die vorhandenen Formatierer-Tests an. Fertig ist die Aufgabe, wenn die vorgeschlagenen Bereichsmarkierungen unterstützt werden und der einzelne Kommentar, der alle folgenden Zeilen ignoriert, ohne Formatierung des eingeschlossenen Codes unterstützt wird.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- csharp, powershell
- Bereich
- tooling
- Issue-Typ
- Feature
- Schwierigkeit
- 4/5
- Geschätzter Aufwand
- 3-5 Tage
- Aktivitätsstatus
- Ruhig
- Klarheit
- Größtenteils klar
- Anfängerfreundlichkeit
- 52/100