Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Spectral install and update #9

Merged
merged 12 commits into from
Jul 12, 2023
Merged

Spectral install and update #9

merged 12 commits into from
Jul 12, 2023

Conversation

guylev008
Copy link
Collaborator

@guylev008 guylev008 commented Jul 9, 2023

Description

Install spectral from the extension & auto-update spectral

Motivation and Context

An easier way to install Spectral from the extension will reduce the user's required setup time.
Keeping the agent updated will provide the user with the latest agent update and rules.

How Has This Been Tested?

  • Spectral agent doesn't exist -> should display the install button at the start
  • Click on install spectral -> should install Spectral agent (display error in the output if failed)
  • Last update date doesn't exist -> should update Spectral agent
  • Last update date is more than one week -> should update Spectral agent
  • Last update date is less than one week -> should not update Spectral agent

Checklist

  • Tests
  • Documentation
  • Linting

CHANGELOG.md Show resolved Hide resolved
Copy link
Member

@barlesh barlesh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what about the case where we release a spectral version with some issues and we revert the version - the extension will downgrade the version only after a week?

@guylev008
Copy link
Collaborator Author

what about the case where we release a spectral version with some issues and we revert the version - the extension will downgrade the version only after a week?

it can be more than a week, the update occurs only in the extension initialization.
there is no way to know that there was a version upgrade.
maybe later we can add an endpoint to our API that returns the latest version so we can check if an update is needed

src/common/spectral-utils.ts Outdated Show resolved Hide resolved
src/common/spectral-utils.ts Outdated Show resolved Hide resolved
src/common/persistence-context.ts Show resolved Hide resolved
src/common/spectral-utils.ts Outdated Show resolved Hide resolved
@guylev008 guylev008 merged commit 748cd7a into main Jul 12, 2023
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants