vanilla-jet 1.0.37 → 1.0.40

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.
@@ -11,8 +11,10 @@ let Config = require(processCwd() + '/config.js');
11
11
 
12
12
  // -- Get environment
13
13
  let env = process.argv[2] || 'development';
14
- if (env === 'dev') { env = 'development'; }
15
- else { env = env.split(':')[1] || ''; }
14
+ if (env === 'dev') { env = 'development'; }
15
+ if (env === 'build:qa') { env = 'qa'; }
16
+ if (env === 'build:staging') { env = 'staging'; }
17
+ if (env === 'build:prod') { env = 'production'; }
16
18
 
17
19
  // -- Init Dipper
18
20
  let settings = Config.settings;
package/bin.js CHANGED
@@ -15,18 +15,33 @@ switch (args[0]) {
15
15
 
16
16
  case 'dev':
17
17
  try {
18
- execSync('grunt --env=development', { stdio: 'inherit', cwd: __dirname });
18
+ execSync('grunt --env=development', { stdio: 'inherit', cwd: __dirname });
19
19
  } catch (error) {
20
- console.error('Error ejecutando grunt:', error.message);
20
+ console.error('Error ejecutando grunt:', error.message);
21
21
  }
22
22
  break;
23
23
 
24
- default:
25
- const isoletedEnv = args[0].split(':')[1];
24
+ case 'build:qa':
26
25
  try {
27
- execSync('grunt build --env=' + isoletedEnv, { stdio: 'inherit', cwd: __dirname });
26
+ execSync('grunt build --env=qa', { stdio: 'inherit', cwd: __dirname });
28
27
  } catch (error) {
29
- console.error('Error ejecutando grunt:', error.message);
28
+ console.error('Error ejecutando grunt:', error.message);
29
+ }
30
+ break;
31
+
32
+ case 'build:staging':
33
+ try {
34
+ execSync('grunt build --env=staging', { stdio: 'inherit', cwd: __dirname });
35
+ } catch (error) {
36
+ console.error('Error ejecutando grunt:', error.message);
37
+ }
38
+ break;
39
+
40
+ case 'build:prod':
41
+ try {
42
+ execSync('grunt build --env=production', { stdio: 'inherit', cwd: __dirname });
43
+ } catch (error) {
44
+ console.error('Error ejecutando grunt:', error.message);
30
45
  }
31
46
  break;
32
47
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vanilla-jet",
3
- "version": "1.0.37",
3
+ "version": "1.0.40",
4
4
  "description": "VannilaJet framework",
5
5
  "main": "index.js",
6
6
  "bin": {