chore: add eslint-plugin-sort and eslint-plugin-prettier#20
Conversation
…ana-foundation#196) * fix: fully support file/folder renaming and content replacement in init script * chore: remove extra underscrore * fix: logging and avoid inline if-statements
…ipt (solana-foundation#196)" (solana-foundation#203) This reverts commit 096f365.
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Description ----------- The "should handle errors gracefully" test was intentionally triggering errors to verify error handling, but `console.error` was not mocked to suppress output, causing noisy `stderr` logs during test despite all tests passing. Testing the introduced fix -------------------------- ``` npm run test ``` All tests will now pass cleanly without `stderr` error output.
…ve-repokit-dependency refactor: remove repokit dependency and replace with local utilities
…eset-release/main Version Packages
…n/ci fix: run ci script as part of e2e test
test: skip community in regular tests
…rror-handling-in-search-and-replace-test fix(test): error handling in search-and-replace test
…kit-templates-default feat: make Kit Framework templates the default
…nit-script-rename-dedup fix: remove buggy deduplication in init-script-rename
…eset-release/main Version Packages
…ublish-latest-tag fix: enable automated npm publish to latest tag
…eset-release/main Version Packages
Add a dedicated task that runs the `setup` script (if present) with a descriptive message "Running setup (building program, generating client)" to improve UX during anchor template installation.
…setup-task-message feat: show setup progress for anchor templates
…eset-release/main Version Packages
…mplate-install feat: support local template install for testing
…tion (#8) Signed-off-by: Dargon789 <[email protected]> Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
Snyk has created this PR to upgrade zod from 4.1.5 to 4.1.8. See this package in npm: zod See this project in Snyk: https://app.snyk.io/org/apichanmittare/project/0c3e0cce-7a92-4f94-90ba-e7eaa0eac00f?utm_source=github&utm_medium=referral&page=upgrade-pr Co-authored-by: snyk-bot <[email protected]>
Snyk has created this PR to upgrade commander from 14.0.0 to 14.0.1. See this package in npm: commander See this project in Snyk: https://app.snyk.io/org/apichanmittare/project/0c3e0cce-7a92-4f94-90ba-e7eaa0eac00f?utm_source=github&utm_medium=referral&page=upgrade-pr Co-authored-by: snyk-bot <[email protected]>
Snyk has created this PR to upgrade semver from 7.7.2 to 7.7.3. See this package in npm: semver See this project in Snyk: https://app.snyk.io/org/apichanmittare/project/0c3e0cce-7a92-4f94-90ba-e7eaa0eac00f?utm_source=github&utm_medium=referral&page=upgrade-pr Co-authored-by: snyk-bot <[email protected]>
* fix: update solana docs url * Version Packages (solana-foundation#206) Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * fix(test): error handling in search-and-replace test Description ----------- The "should handle errors gracefully" test was intentionally triggering errors to verify error handling, but `console.error` was not mocked to suppress output, causing noisy `stderr` logs during test despite all tests passing. Testing the introduced fix -------------------------- ``` npm run test ``` All tests will now pass cleanly without `stderr` error output. * refactor: remove repokit dependency and replace with local utilities * fix: update imports and Zod types for compatibility * Version Packages * fix: run ci script as part of e2e test * test: skip community in regular tests * skip again test workflow on PR since we tested it now skips community * feat: make Kit Framework templates the default * fix: remove buggy deduplication in init-script-rename * chore: remove test templates job (solana-foundation#221) * fix: apply path rename only to entry name, not full path * Version Packages * fix: enable automated npm publish to latest tag * Version Packages * feat: show setup progress for anchor templates Add a dedicated task that runs the `setup` script (if present) with a descriptive message "Running setup (building program, generating client)" to improve UX during anchor template installation. * Version Packages * feat: support local template install for testing * feat: add warning for installing local templates --------- Co-authored-by: Bram Borggreve <[email protected]> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: 0xObsidian <[email protected]> Co-authored-by: guibibeau <[email protected]> Co-authored-by: Gui Bibeau <[email protected]> Co-authored-by: Sourav Mishra <[email protected]>
* Create config.yml 148313f 484b187 49c4050 4539b38 Signed-off-by: Dargon789 <[email protected]> * Update .circleci/config.yml Co-authored-by: sourcery-ai[bot] <58596630+sourcery-ai[bot]@users.noreply.github.com> Signed-off-by: Dargon789 <[email protected]> --------- Signed-off-by: Dargon789 <[email protected]> Co-authored-by: sourcery-ai[bot] <58596630+sourcery-ai[bot]@users.noreply.github.com>
…reateapp-pipeline-with-setup-script'
in commit `813773d4`, @beeman mentioned that `paths` should be renamed to `in`. This PR basically adds support for it + maintain backward compatibility. Feat added ---------- - Accepts `in` alias alongside `paths` in rename entries - Normalizes `in` to `paths` in `InitScriptSchemaRename` - Added tests for alias and existing `paths` behavior Implementation test ------------------- pnpm vitest run test/init-script-schema.test.ts pnpm test Co-authored-by: 0xObsidian <[email protected]>
Replace the GitHub Actions-based npm snapshot publishing workflow with a CircleCI-style workflow that runs tests using Bun via the CircleCI Node orb. CI: Introduce a new CircleCI-style test job using the node orb and Bun to run the test suite. Remove the previous GitHub Actions steps that built the project and published npm snapshots to pkg.pr.new. Signed-off-by: Dargon789 <[email protected]>
There was a problem hiding this comment.
Sorry @Dargon789, you have reached your weekly rate limit of 500000 diff characters.
Please try again later or upgrade to continue using Sourcery
✅ Snyk checks have passed. No issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
Summary of ChangesHello @Dargon789, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request significantly overhauls the project's internal architecture and user experience. It streamlines template management by replacing an external dependency with a custom solution, enabling more robust and flexible template creation, including support for local templates. The post-installation Highlights
Ignored Files
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
ba6ce49
into
9-sequence-diagram-for-updated-createapp-pipeline-with-setup-script
There was a problem hiding this comment.
Code Review
This pull request significantly refactors the template handling and project setup process, moving away from the external @beeman/repokit dependency to local utility modules for template schema, fetching, and menu logic. Key changes include introducing a new lefthook.yml for pre-commit hooks (replacing previous husky scripts) to manage linting and formatting, and updating the ESLint configuration with new sorting rules. The create-solana-dapp CLI now supports local template paths, a --minimal flag for quick setup, and a --list-template-ids option. The project setup flow has been enhanced with a new task to run an optional setup script (e.g., for Anchor program builds) and improved init script execution, which now includes version checks for Anchor and Solana, and more robust template renaming logic to prevent path duplication. Minor stylistic changes, such as reordering object properties and adding blank lines for readability, were also applied across various files, likely due to the new ESLint sorting rules.
| @@ -6,7 +6,6 @@ import { initializeGitRepo } from './vendor/git' | |||
| export function createAppTaskInitializeGit(args: GetArgsResult): Task { | |||
| return { | |||
| enabled: !args.skipGit, | |||
There was a problem hiding this comment.
| values: Template[], | ||
| ): SelectOptions<{ value: Template; label: string; hint?: string | undefined }[], Template> { | ||
| ): SelectOptions<{ hint?: string | undefined; label: string; value: Template }[], Template> { |
There was a problem hiding this comment.
The order of properties in the SelectOptions type definition has been reordered. This is a stylistic change, likely due to the newly introduced sort/type-properties ESLint rule. Please ensure consistent property ordering.
): SelectOptions<{ hint?: string | undefined; label: string; value: Template }[], Template> {| return undefined | ||
| } | ||
| } | ||
|
|
| function checkGitUserName(): string | undefined { | ||
| return runCheck('git config --global user.name') ?? 'bot' | ||
| } | ||
|
|
| propertyName: toPropertyName(name), | ||
| } | ||
| } | ||
|
|
| } | ||
| } | ||
| } | ||
|
|
| instructions: [], | ||
| name: 'test-project', | ||
| targetDirectory: '/template', | ||
| packageManager: 'npm', | ||
| skipGit: false, | ||
| skipInit: false, | ||
| skipInstall: false, | ||
| template: { name: 'basic', description: 'description', repository: '/template' }, | ||
| verbose: false, | ||
| target: 'test-project', | ||
| instructions: [], | ||
| targetDirectory: '/template', | ||
| template: { description: 'description', name: 'basic', repository: '/template' }, | ||
| verbose: false, |
There was a problem hiding this comment.
The order of properties in the baseArgs object has been reordered. This is a stylistic change, likely due to the newly introduced sort/type-properties ESLint rule. Please ensure consistent property ordering in test data.
| instructions: [], | |
| name: 'test-project', | |
| targetDirectory: '/template', | |
| packageManager: 'npm', | |
| skipGit: false, | |
| skipInit: false, | |
| skipInstall: false, | |
| template: { name: 'basic', description: 'description', repository: '/template' }, | |
| verbose: false, | |
| target: 'test-project', | |
| instructions: [], | |
| targetDirectory: '/template', | |
| template: { description: 'description', name: 'basic', repository: '/template' }, | |
| verbose: false, | |
| dryRun: false, | |
| instructions: [], | |
| name: 'test-project', | |
| packageManager: 'npm', | |
| skipGit: false, | |
| skipInit: false, | |
| skipInstall: false, | |
| target: 'test-project', | |
| targetDirectory: '/template', | |
| template: { description: 'description', name: 'basic', repository: '/template' }, |
| packageManager: 'npm', | ||
| skipGit: false, | ||
| skipInit: false, | ||
| skipInstall: false, | ||
| template: { name: 'basic', description: 'description', repository: '/template' }, | ||
| targetDirectory: '/template', | ||
| template: { description: 'description', name: 'basic', repository: '/template' }, |
There was a problem hiding this comment.
The order of properties in the baseArgs object has been reordered. This is a stylistic change, likely due to the newly introduced sort/type-properties ESLint rule. Please ensure consistent property ordering in test data.
| packageManager: 'npm', | |
| skipGit: false, | |
| skipInit: false, | |
| skipInstall: false, | |
| template: { name: 'basic', description: 'description', repository: '/template' }, | |
| targetDirectory: '/template', | |
| template: { description: 'description', name: 'basic', repository: '/template' }, | |
| name: 'test-project', | |
| packageManager: 'npm', | |
| skipGit: false, | |
| skipInit: false, | |
| skipInstall: false, | |
| targetDirectory: '/template', |
f1dd440
49c4050
484b187