question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Add better support for footer issue references

See original GitHub issue

Currently, when autocompleting a footer token, a colon is always added. While this is the desired behavior in most cases, the conventional commit specification states that this should not be done, if followed by an issue reference, e.g. Closes #123:

Each footer MUST consist of a word token, followed by either a :<space> or <space># separator, followed by a string value (this is inspired by the git trailer convention).

~ Conventional Commit Spec, Point 8

Possible Implementation

First of all, when linting the commit message, a warning should be shown, if the footer’s value starts with “: #”. This could be paired with the option to auto-fix this, depending on whether the footer’s value is an issue reference or plain text, to remove the colon or the '#`, respectively.

Additionally, an “issue reference” option could be added to the footer types settings. This should be turned on for Closes, Implements, and Refs. If turned on, " #" will be inserted after the token, instead of ": ". This should cover most cases, as issue refs are mostly used for those three.

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:1
  • Comments:12 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
lppeddcommented, Jun 8, 2022

The lexer now works correctly with both cases. This issue will be closed when a completion contributor based on the PSI structure is implemented, potentially in 0.22.0.

1reaction
mavolincommented, Nov 25, 2020

No, not at all. Take any time you need.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Add option to add footer as well as header · Issue #368 - GitHub
Add option for a footer section similar to the headers section which comes after the inputs/outputs etc. Describe alternatives you've considered.
Read more >
Inserting Division References in Headers and Footers
Place your cursor in the middle cell of the table, then choose Insert > Division Reference.
Read more >
Insert data from the form in a header or footer - Microsoft Support
Insert data from the form in a header or footer · On the View menu, click Header and Footer. · Click the Print...
Read more >
<footer> - HTML: HyperText Markup Language - MDN Web Docs
The HTML element represents a footer for its nearest ancestor sectioning content or sectioning root element.
Read more >
Use headers, footers, page numbers, & footnotes - Google Help
You can use footnotes to add references in your Google Doc. In documents that are in pages format, you can add page numbers,...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found