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.

Setup CHANGELOG.md automatically

See original GitHub issue

When running `` the first time and ther is no CHANGELOG.md file present i get the following error:

Error: fatal: pathspec ‘path/to/lib/CHANGELOG.md’ did not match any files

In such a case we could create the file if it does not exist

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:1
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
bcdxncommented, May 19, 2022

I see the same issue. For the record, this is a project that has been migrated to NX so it has a lot of history but no ‘last-version’ tag or any previous version tag that this plugin would recognize (not sure if that matters).

When i run: nx affected --target=version --baseBranch=master --dryRun --head=HEAD --base=master --releaseAs=prerelease --preid=rc

I get the following error for every app and package in the repository:

✖  nx run user-session:version
       [user-session] 🟠 No previous version tag found, fallback to version 0.0.0.
               New version will be calculated based on all changes since first commit.
               If your project is already versioned, please tag the latest release commit with user-session-x.y.z and run this command again.
       [user-session] 🆕 Calculated new version "0.0.1-rc.0".
       
       ---
       ### 0.0.1-rc.0 (2022-05-19)
       
       
       ### Features
       
       * migration to nx monorepo
       ---
       
       [user-session] 📜 Generated CHANGELOG.md.
       [user-session] ❌ Error: fatal: pathspec '<path-to-file>/packages/user-session/CHANGELOG.md' did not match any files
       
           at <path-to-file>/node_modules/@jscutlery/semver/src/executors/common/exec.js:10:34
           at ChildProcess.exithandler (node:child_process:406:5)
           at ChildProcess.emit (node:events:527:28)
           at maybeClose (node:internal/child_process:1092:16)
           at Socket.<anonymous> (node:internal/child_process:451:11)
           at Socket.emit (node:events:527:28)
           at Pipe.<anonymous> (node:net:709:12)
0reactions
edbzncommented, Jun 17, 2022

Maybe it’s happening only on Windows because on Linux I can’t reproduce.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How To Automatically Generate A Helpful Changelog From ...
Auto -Generate Changelog · Follow the Conventional Commits Specification in your repository. We will use @commitlint/config-conventional to enforce this via Git ...
Read more >
cookpete/auto-changelog: Command line tool for ... - GitHub
Simply run auto-changelog in the root folder of a git repository. git log is run behind the scenes in order to parse the...
Read more >
Automatically generate and release a changelog using Node.js
In this tutorial, we'll explore a method for automatically generating and releasing a changelog that uses git hooks and Node.js.
Read more >
Automatic Changelog and Versioning with GIT
Below you can find a sample configuration for GitLab CI/CD to automatically generate a CHANGELOG.md file on a push to the main branch....
Read more >
auto-changelog - npm
Command line tool for generating a changelog from git tags and commit history. Latest version: 2.4.0, last published: a year ago.
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