create-payload-app 0.3.11 → 0.3.12

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.
@@ -159,7 +159,7 @@ function updatePayloadVersion(projectDir, betaFlag) {
159
159
  exports.updatePayloadVersion = updatePayloadVersion;
160
160
  function createProject(args, projectDir, template, packageManager) {
161
161
  return __awaiter(this, void 0, void 0, function () {
162
- var templateDir, emitter, src, dest, err_2, msg, spinner, result;
162
+ var templateDir, emitter, src, dest, gi, giDest, err_2, msg, spinner, result;
163
163
  return __generator(this, function (_a) {
164
164
  switch (_a.label) {
165
165
  case 0: return [4 /*yield*/, createProjectDir(projectDir)];
@@ -172,9 +172,9 @@ function createProject(args, projectDir, template, packageManager) {
172
172
  return [4 /*yield*/, emitter.clone(projectDir)];
173
173
  case 2:
174
174
  _a.sent();
175
- return [3 /*break*/, 8];
175
+ return [3 /*break*/, 9];
176
176
  case 3:
177
- _a.trys.push([3, 7, , 8]);
177
+ _a.trys.push([3, 8, , 9]);
178
178
  return [4 /*yield*/, fs_extra_1.default.copy(templateDir, projectDir, { recursive: true })];
179
179
  case 4:
180
180
  _a.sent();
@@ -186,22 +186,27 @@ function createProject(args, projectDir, template, packageManager) {
186
186
  _a.sent();
187
187
  _a.label = 6;
188
188
  case 6:
189
- (0, log_1.success)('Project directory created');
190
- return [3 /*break*/, 8];
189
+ gi = path_1.default.resolve(templateDir, '..', 'gitignore.template');
190
+ giDest = path_1.default.resolve(projectDir, '.gitignore');
191
+ return [4 /*yield*/, fs_extra_1.default.copy(gi, giDest)];
191
192
  case 7:
193
+ _a.sent();
194
+ (0, log_1.success)('Project directory created');
195
+ return [3 /*break*/, 9];
196
+ case 8:
192
197
  err_2 = _a.sent();
193
198
  msg = 'Unable to copy template files. Please check template name or directory permissions.';
194
199
  (0, log_1.error)(msg);
195
200
  process.exit(1);
196
- return [3 /*break*/, 8];
197
- case 8:
201
+ return [3 /*break*/, 9];
202
+ case 9:
198
203
  spinner = (0, ora_1.default)('Checking latest Payload version...').start();
199
204
  return [4 /*yield*/, updatePayloadVersion(projectDir, args['--beta'])];
200
- case 9:
205
+ case 10:
201
206
  _a.sent();
202
207
  spinner.text = 'Installing dependencies...';
203
208
  return [4 /*yield*/, installDeps(args, projectDir, packageManager)];
204
- case 10:
209
+ case 11:
205
210
  result = _a.sent();
206
211
  spinner.stop();
207
212
  spinner.clear();
@@ -0,0 +1,166 @@
1
+ ### Node ###
2
+ # Logs
3
+ logs
4
+ *.log
5
+ npm-debug.log*
6
+ yarn-debug.log*
7
+ yarn-error.log*
8
+ lerna-debug.log*
9
+ .pnpm-debug.log*
10
+
11
+ # Diagnostic reports (https://nodejs.org/api/report.html)
12
+ report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json
13
+
14
+ # Runtime data
15
+ pids
16
+ *.pid
17
+ *.seed
18
+ *.pid.lock
19
+
20
+ # Directory for instrumented libs generated by jscoverage/JSCover
21
+ lib-cov
22
+
23
+ # Coverage directory used by tools like istanbul
24
+ coverage
25
+ *.lcov
26
+
27
+ # nyc test coverage
28
+ .nyc_output
29
+
30
+ # Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
31
+ .grunt
32
+
33
+ # Bower dependency directory (https://bower.io/)
34
+ bower_components
35
+
36
+ # node-waf configuration
37
+ .lock-wscript
38
+
39
+ # Compiled binary addons (https://nodejs.org/api/addons.html)
40
+ build/Release
41
+
42
+ # Dependency directories
43
+ node_modules/
44
+ jspm_packages/
45
+
46
+ # Snowpack dependency directory (https://snowpack.dev/)
47
+ web_modules/
48
+
49
+ # TypeScript cache
50
+ *.tsbuildinfo
51
+
52
+ # Optional npm cache directory
53
+ .npm
54
+
55
+ # Optional eslint cache
56
+ .eslintcache
57
+
58
+ # Optional stylelint cache
59
+ .stylelintcache
60
+
61
+ # Microbundle cache
62
+ .rpt2_cache/
63
+ .rts2_cache_cjs/
64
+ .rts2_cache_es/
65
+ .rts2_cache_umd/
66
+
67
+ # Optional REPL history
68
+ .node_repl_history
69
+
70
+ # Output of 'npm pack'
71
+ *.tgz
72
+
73
+ # Yarn Integrity file
74
+ .yarn-integrity
75
+
76
+ # dotenv environment variable files
77
+ .env
78
+ .env.development.local
79
+ .env.test.local
80
+ .env.production.local
81
+ .env.local
82
+
83
+ # parcel-bundler cache (https://parceljs.org/)
84
+ .cache
85
+ .parcel-cache
86
+
87
+ # Next.js build output
88
+ .next
89
+ out
90
+
91
+ # Nuxt.js build / generate output
92
+ .nuxt
93
+ dist
94
+
95
+ # Gatsby files
96
+ .cache/
97
+ # Comment in the public line in if your project uses Gatsby and not Next.js
98
+ # https://nextjs.org/blog/next-9-1#public-directory-support
99
+ # public
100
+
101
+ # vuepress build output
102
+ .vuepress/dist
103
+
104
+ # vuepress v2.x temp and cache directory
105
+ .temp
106
+
107
+ # Docusaurus cache and generated files
108
+ .docusaurus
109
+
110
+ # Serverless directories
111
+ .serverless/
112
+
113
+ # FuseBox cache
114
+ .fusebox/
115
+
116
+ # DynamoDB Local files
117
+ .dynamodb/
118
+
119
+ # TernJS port file
120
+ .tern-port
121
+
122
+ # Stores VSCode versions used for testing VSCode extensions
123
+ .vscode-test
124
+
125
+ # yarn v2
126
+ .yarn/cache
127
+ .yarn/unplugged
128
+ .yarn/build-state.yml
129
+ .yarn/install-state.gz
130
+ .pnp.*
131
+
132
+ ### Node Patch ###
133
+ # Serverless Webpack directories
134
+ .webpack/
135
+
136
+ # Optional stylelint cache
137
+
138
+ # SvelteKit build / generate output
139
+ .svelte-kit
140
+
141
+ ### VisualStudioCode ###
142
+ .vscode/*
143
+ !.vscode/settings.json
144
+ !.vscode/tasks.json
145
+ !.vscode/launch.json
146
+ !.vscode/extensions.json
147
+ !.vscode/*.code-snippets
148
+
149
+ # Local History for Visual Studio Code
150
+ .history/
151
+
152
+ # Built Visual Studio Code Extensions
153
+ *.vsix
154
+
155
+ ### VisualStudioCode Patch ###
156
+ # Ignore all local history of files
157
+ .history
158
+ .ionide
159
+
160
+ # Support for Project snippet scope
161
+ .vscode/*.code-snippets
162
+
163
+ # Ignore code-workspaces
164
+ *.code-workspace
165
+
166
+ # End of https://www.toptal.com/developers/gitignore/api/node,visualstudiocode
package/package.json CHANGED
@@ -31,7 +31,7 @@
31
31
  "prompts": "^2.4.0",
32
32
  "terminal-link": "^2.1.1"
33
33
  },
34
- "version": "0.3.11",
34
+ "version": "0.3.12",
35
35
  "devDependencies": {
36
36
  "@types/command-exists": "^1.2.0",
37
37
  "@types/degit": "^2.8.3",