@himamshus06/git-auto 1.3.6 → 1.3.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/tree.js +3 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@himamshus06/git-auto",
3
- "version": "1.3.6",
3
+ "version": "1.3.7",
4
4
  "description": "",
5
5
  "main": "src/index.js",
6
6
  "bin": {
package/src/tree.js CHANGED
@@ -47,7 +47,9 @@ function parseTree(text) {
47
47
  }
48
48
 
49
49
  // Strip any remaining connector/line-drawing/space characters to get the name.
50
- const name = rest.replace(new RegExp(`^${PREFIX_CHARS.source}+`), '').trim();
50
+ let name = rest.replace(new RegExp(`^${PREFIX_CHARS.source}+`), '').trim();
51
+ // Strip a trailing inline comment (" # explanation"), if present.
52
+ name = name.replace(/\s+#.*$/, '').trim();
51
53
  if (!name) continue;
52
54
 
53
55
  if (depth > stack.length) {