wp-blank-scripts 2.6.10 → 2.6.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -278,7 +278,7 @@ module.exports = async (selectOptions, callbacks) => {
278
278
 
279
279
  if (options.sql) {
280
280
  if (isCI()) {
281
- return deploySQLFromCI();
281
+ return deploySQLFromCI(options);
282
282
  }
283
283
 
284
284
  const file = await exportSql({ environment: options.environment });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "wp-blank-scripts",
3
- "version": "2.6.10",
3
+ "version": "2.6.11",
4
4
  "description": "Personal Wordpress Scripts",
5
5
  "main": "index.js",
6
6
  "bin": {
@@ -5,10 +5,17 @@ const getSettings = require('./projectSettings');
5
5
 
6
6
  const DEPLOY_URL = 'https://57e5-60-241-189-248.au.ngrok.io/prod/deploy';
7
7
 
8
- async function deploySQLFromCI() {
8
+ async function deploySQLFromCI(options) {
9
9
  const { default: fetch } = await import('node-fetch');
10
10
  const file = getMostRecentSqlFile(true);
11
11
  console.log({ file, repo });
12
+
13
+ await replaceSQL({
14
+ environmentIn: 'local',
15
+ environmentOut: options.environment,
16
+ file,
17
+ });
18
+
12
19
  const sql = fs.readFileSync(file, 'utf8');
13
20
 
14
21
  const response = await fetch(DEPLOY_URL, {