-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #172 from wp-graphql/refactor-plugins
refactor: Refactor plugins
- Loading branch information
Showing
14 changed files
with
357 additions
and
144 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"wpgraphql-ide": patch | ||
--- | ||
|
||
- Remove npm workspaces and have webpack handle compiling of the main app and internal plugins. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
#!/usr/bin/env node | ||
|
||
const { execSync } = require('child_process'); | ||
const path = require('path'); | ||
const glob = require('glob'); | ||
|
||
// Define the path to the plugins directory | ||
const pluginsPath = path.resolve(__dirname, '../plugins'); | ||
|
||
// Use glob to find all plugin directories | ||
const plugins = glob.sync(`${pluginsPath}/*`); | ||
|
||
// Function to start a plugin using wp-scripts | ||
const startPlugin = (plugin) => { | ||
const pluginName = path.basename(plugin); | ||
console.log(`Starting plugin: ${pluginName}`); | ||
execSync('wp-scripts start', { | ||
cwd: plugin, | ||
stdio: 'inherit', | ||
}); | ||
}; | ||
|
||
// Start each plugin | ||
plugins.forEach(startPlugin); |
0
bin/versionPlugin.js → bin/version-plugin.js
100644 → 100755
File renamed without changes.
Oops, something went wrong.