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

Spec version filter for cli init #751

Merged
merged 8 commits into from
Jan 17, 2022
Merged

Conversation

fishmonger45
Copy link
Contributor

Adds a filter of templates for users chosen specVersion. If there are no templates for that specVersion (which should not be the case) then it falls back to a custom git remote & branch.

@fishmonger45
Copy link
Contributor Author

fishmonger45 commented Jan 14, 2022

  it('should return a project schema object', async () => {
    reader = new IPFSReader('QmYyCCSaHLpPvZmex5ExHGdW7mavKYeiixVEyvNGwD1LLw', IPFSGateway);

    const data: any = await reader.getProjectSchema();

    expect(data.repository).toBe('https://github.com/subquery/subql-starter');
  });
});

https://github.com/wqsz7xn/subql/blob/023fb851dd084dd9f4ddcec3b123251b70d9d57a/packages/validator/src/readers/ipfs-reader.spec.ts#L12-L18

Following test is flaky

@fishmonger45
Copy link
Contributor Author

Let me put back in the --starter flag before merging this. I don't know where it disappeared. My bad

@fishmonger45
Copy link
Contributor Author

Added back the --starter flag so that I don't have to change a bunch of docs

@ianhe8x
Copy link
Collaborator

ianhe8x commented Jan 16, 2022

The template feature is a replacement for the original --starter. With --starter, it skips template selection. I think we should move on without --starter

@fishmonger45 fishmonger45 merged commit bcf0cfc into main Jan 17, 2022
bz888 pushed a commit that referenced this pull request Jun 3, 2022
* spec version filter for init

* use lodash and move inquirer setup after imports

* add back --starter flag

* Remove starter flag

* unused import

* update project defaults test

* fix test

* Add comments
@stwiname stwiname deleted the spec-version-template-filter branch May 15, 2023 23:02
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.

2 participants