Info/Warning: there's a new version of the X template
- Dominant language
- JavaScript
- Stars
- 1.1k
- Forks
- 397
- Avg merge
- 1d 18h
- Merged PRs (30d)
- 26
Description
#### Reason/Context
By default, npm will not install new versions of a template because it finds it's already installed and skips the installation process. This is a good thing in most cases but can create confusion when someone is trying to use a template and they don't get the latest version features and fixes.
Users can overcome this by executing something like:
```bash
ag asyncapi.yml @asyncapi/html-template@latest -o output
# Notice the `@latest`
```
But that's something you do when you really know how the Generator works.
#### Description
I suggest we add a console.info indicating that a template has a new version available. Something like:
```
This template has a newer version and you can safely update.
Use `@asyncapi/html-template@latest` as your template name to install the latest version.
Example:
ag asyncapi.yml @asyncapi/html-template@latest -o output
```
Contributor guide
Research direction
Start from the `ag asyncapi.yml @asyncapi/html-template@latest -o output` command and trace the template installation path. Determine where the installed template version can be compared with a newer version, then verify that the requested informational message appears only when an update is available.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, nodejs
- Domain
- cli
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100