File tree Expand file tree Collapse file tree
theme-component-generator
vscode-extension/src/node Expand file tree Collapse file tree Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ on :
2+ # allow manual triggering of the workflow
3+ workflow_dispatch :
4+ # Required for Repository Ruleset workflows
5+ push :
6+
7+ # Add this permissions block
8+ permissions :
9+ actions : read
10+ pull-requests : read
11+ security-events : write
12+ id-token : write
13+ contents : read
14+
15+ jobs :
16+ Security-Code-Scanner :
17+ uses : shopify-playground/github-actions/.github/workflows/security-code-scanner-workflow.yml@main
18+ secrets :
19+ token : ${{ secrets.GITHUB_TOKEN }}
Original file line number Diff line number Diff line change 77 "scripts" : {
88 "start" : " node --experimental-strip-types src/index.ts" ,
99 "dev" : " node --experimental-strip-types --watch src/index.ts" ,
10- "build" : " echo noop"
10+ "build" : " echo noop" ,
11+ "build:ts" : " echo noop" ,
12+ "build:ci" : " echo noop" ,
13+ "postbuild:ts" : " echo noop" ,
14+ "generate-factory-configs" : " echo noop" ,
15+ "type-check" : " echo noop" ,
16+ "test" : " echo noop"
1117 },
1218 "keywords" : [
1319 " mcp" ,
2935 "@types/node" : " ^20.0.0"
3036 },
3137 "engines" : {
32- "node" : " >=22.0.0 "
38+ "node" : " >=18.20.8 "
3339 }
3440}
Original file line number Diff line number Diff line change 1- import { McpServer } from " @modelcontextprotocol/sdk/server/mcp.js" ;
2- import { StdioServerTransport } from " @modelcontextprotocol/sdk/server/stdio.js" ;
1+ import { McpServer } from ' @modelcontextprotocol/sdk/server/mcp.js' ;
2+ import { StdioServerTransport } from ' @modelcontextprotocol/sdk/server/stdio.js' ;
33
4- import { defineComponentGenerator } from " ./components.ts" ;
4+ import { defineComponentGenerator } from ' ./components.ts' ;
55
66const server = new McpServer ( {
7- name : " theme-component-generator" ,
8- version : " 1.0.0" ,
7+ name : ' theme-component-generator' ,
8+ version : ' 1.0.0' ,
99} ) ;
1010
1111defineComponentGenerator ( server ) ;
Original file line number Diff line number Diff line change @@ -168,15 +168,19 @@ async function createMCPConfig(configPath: string) {
168168 }
169169
170170 /*
171- * The path ONLY works on local environments.
172- * To be able to reference the MCP in production, we need to update the path to be a reference to a published
173- * NPM package.
174- */
171+ * The path ONLY works on local environments.
172+ * To be able to reference the MCP in production, we need to update the path to be a reference to a published
173+ * NPM package.
174+ */
175175 const mcpConfig = {
176- [ detectEditor ( ) === 'vscode' ? 'servers' : 'mcpServers' ] : {
176+ [ detectEditor ( ) === 'vscode' ? 'servers' : 'mcpServers' ] : {
177177 themeComponentGenerator : {
178178 command : 'node' ,
179- args : [ "--experimental-strip-types" , __dirname . match ( / ^ .* ?t h e m e - t o o l s \/ p a c k a g e s / ) ?. [ 0 ] + "/theme-component-generator/src/index.ts" ] ,
179+ args : [
180+ '--experimental-strip-types' ,
181+ __dirname . match ( / ^ .* ?t h e m e - t o o l s \/ p a c k a g e s / ) ?. [ 0 ] +
182+ '/theme-component-generator/src/index.ts' ,
183+ ] ,
180184 env : { } ,
181185 } ,
182186 } ,
@@ -193,13 +197,9 @@ function detectEditor(): string | undefined {
193197 return 'cursor' ;
194198 }
195199
196- if (
197- appName . includes ( 'vscode' ) ||
198- appName . includes ( 'visual studio code' )
199- ) {
200+ if ( appName . includes ( 'vscode' ) || appName . includes ( 'visual studio code' ) ) {
200201 return 'vscode' ;
201202 }
202203
203204 return ;
204205}
205-
You can’t perform that action at this time.
0 commit comments