github / github/gh-stack

`gh stack submit` with PULL_REQUEST_TEMPLATE.md that has `CRLF` line endings

Offen
#384 2 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
bug topic: cli - submit
Vorherrschende Sprache
Go
Sterne
1.5k
Forks
70
Ø Merge
1 T. 8 Std.
Gemergte PRs (30 T.)
7

Beschreibung

**Problem**
Submit is rendering extra line endings when it sees `CRLF`. Opening in the $EDITOR also has these extra line endings.

**Descirption**
When developing on Windows, it is common for git to normalize line endings to CRLF and then back to LF on commit.

On Windows, given a template with the following:

Image

It opens in the submit editor like this (each red mark is an extra newline):

Image

I replaced `CRLF` with `LF`, and then it works fine.

I have workarounds, just a minor inconvenience.

Beitragsleitfaden

Beitragsleitfaden öffnen

Rechercherichtung

Reproduce the issue on Windows with a CRLF PULL_REQUEST_TEMPLATE.md, then trace the gh stack submit path that loads the template and opens the editor. Confirm the fix by checking that the template displays without extra line endings and that the existing workaround is no longer needed.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
git, go
Bereich
cli
Issue-Typ
Bug
Schwierigkeit
3/5
Geschätzter Aufwand
1-2 Tage
Aktivitätsstatus
Ruhig
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
55/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.