directus-template-cli 0.5.0-beta.1 → 0.5.0-beta.2

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.
@@ -81,7 +81,9 @@ class ApplyCommand extends core_1.Command {
81
81
  core_1.ux.log(separator);
82
82
  // Get Directus URL and token
83
83
  const directusUrl = await (0, auth_1.getDirectusUrl)();
84
- await (0, auth_1.getDirectusToken)(directusUrl);
84
+ const directusToken = await (0, auth_1.getDirectusToken)(directusUrl);
85
+ flags.directusUrl = directusUrl;
86
+ flags.directusToken = directusToken;
85
87
  if (template) {
86
88
  core_1.ux.log(`Applying template - ${template.templateName} to ${directusUrl}`);
87
89
  await (0, index_js_1.default)(template.directoryPath, validatedFlags);
@@ -174,7 +176,7 @@ ApplyCommand.description = 'Apply a template to a blank Directus instance.';
174
176
  ApplyCommand.examples = [
175
177
  '$ directus-template-cli apply',
176
178
  '$ directus-template-cli apply -p --directusUrl="http://localhost:8055" --directusToken="admin-token-here" --templateLocation="./my-template" --templateType="local"',
177
- '$ directus-template-cli apply -p --directusUrl="http://localhost:8055" --directusToken="admin-token-here" --templateLocation="./my-template" --templateType="local" --partial --no-content --no-users',
179
+ '$ directus-template-cli@beta apply -p --directusUrl="http://localhost:8055" --directusToken="admin-token-here" --templateLocation="./my-template" --templateType="local" --partial --no-content --no-users',
178
180
  ];
179
181
  ApplyCommand.flags = {
180
182
  content: core_1.Flags.boolean({
@@ -57,7 +57,9 @@ class ExtractCommand extends core_1.Command {
57
57
  core_1.ux.log(`You selected ${directory}`);
58
58
  // Get Directus URL and token
59
59
  const directusUrl = await (0, auth_1.getDirectusUrl)();
60
- await (0, auth_1.getDirectusToken)(directusUrl);
60
+ const directusToken = await (0, auth_1.getDirectusToken)(directusUrl);
61
+ flags.directusUrl = directusUrl;
62
+ flags.directusToken = directusToken;
61
63
  await this.extractTemplate(templateName, directory, flags);
62
64
  }
63
65
  async runProgrammatic(flags) {
@@ -39,8 +39,8 @@ async function apply(dir, flags) {
39
39
  await (0, load_users_1.default)(source);
40
40
  }
41
41
  if (flags.files) {
42
- await (0, load_files_1.default)(source);
43
42
  await (0, load_folders_1.default)(source);
43
+ await (0, load_files_1.default)(source);
44
44
  }
45
45
  if (flags.content) {
46
46
  await (0, load_data_1.default)(source);
@@ -7,7 +7,7 @@
7
7
  "examples": [
8
8
  "$ directus-template-cli apply",
9
9
  "$ directus-template-cli apply -p --directusUrl=\"http://localhost:8055\" --directusToken=\"admin-token-here\" --templateLocation=\"./my-template\" --templateType=\"local\"",
10
- "$ directus-template-cli apply -p --directusUrl=\"http://localhost:8055\" --directusToken=\"admin-token-here\" --templateLocation=\"./my-template\" --templateType=\"local\" --partial --no-content --no-users"
10
+ "$ directus-template-cli@beta apply -p --directusUrl=\"http://localhost:8055\" --directusToken=\"admin-token-here\" --templateLocation=\"./my-template\" --templateType=\"local\" --partial --no-content --no-users"
11
11
  ],
12
12
  "flags": {
13
13
  "content": {
@@ -234,5 +234,5 @@
234
234
  ]
235
235
  }
236
236
  },
237
- "version": "0.5.0-beta.1"
237
+ "version": "0.5.0-beta.2"
238
238
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "directus-template-cli",
3
- "version": "0.5.0-beta.1",
3
+ "version": "0.5.0-beta.2",
4
4
  "description": "CLI Utility for applying templates to a Directus instance.",
5
5
  "author": "bryantgillespie @bryantgillespie",
6
6
  "bin": {