Skip to content

Commit 72ca1c5

Browse files
author
Chris Brody
authored
refactor: nudge indenting of options in logging (#436)
* refactor: nudge indenting of options in logging also fixes minor misalignment that was introduced in 8bfc561 (PR #431) * update test snapshot
1 parent 8f8a9c5 commit 72ca1c5

File tree

8 files changed

+125
-125
lines changed

8 files changed

+125
-125
lines changed

lib/lib.js

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -103,25 +103,25 @@ const generateWithNormalizedOptions = ({
103103
info(
104104
`CREATE new React Native module with the following options:
105105
106-
name: ${name}
107-
full package name: ${packageName}
108-
is view: ${view}
109-
object class name: ${objectClassName}
110-
Android nativePackageId: ${nativePackageId}
111-
platforms: ${platforms}
112-
Apple tvosEnabled: ${tvosEnabled}
113-
authorName: ${authorName}
114-
authorEmail: ${authorEmail}
115-
author githubAccount: ${githubAccount}
116-
license: ${license}
117-
useAppleNetworking: ${useAppleNetworking}
106+
name: ${name}
107+
full package name: ${packageName}
108+
is view: ${view}
109+
object class name: ${objectClassName}
110+
Android nativePackageId: ${nativePackageId}
111+
platforms: ${platforms}
112+
Apple tvosEnabled: ${tvosEnabled}
113+
authorName: ${authorName}
114+
authorEmail: ${authorEmail}
115+
author githubAccount: ${githubAccount}
116+
license: ${license}
117+
useAppleNetworking: ${useAppleNetworking}
118118
` + (generateExample
119119
? `
120-
generateExample: ${generateExample}
121-
exampleFileLinkage: ${exampleFileLinkage}
122-
exampleName: ${exampleName}
123-
exampleReactNativeTemplate: ${exampleReactNativeTemplate}
124-
writeExamplePodfile: ${writeExamplePodfile}
120+
generateExample: ${generateExample}
121+
exampleFileLinkage: ${exampleFileLinkage}
122+
exampleName: ${exampleName}
123+
exampleReactNativeTemplate: ${exampleReactNativeTemplate}
124+
writeExamplePodfile: ${writeExamplePodfile}
125125
` : ``));
126126

127127
// QUICK LOCAL INJECTION overwite of existing execSync / commandSync call from

tests/with-mocks/cli/command/action-func/with-logging/with-bogus-platforms/bogus-name/__snapshots__/cli-command-with-bogus-platforms-name.test.js.snap

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -12,18 +12,18 @@ Array [
1212
"info": Array [
1313
"CREATE new React Native module with the following options:
1414
15-
name: alice-bobbi
16-
full package name: react-native-alice-bobbi
17-
is view: false
18-
object class name: AliceBobbi
19-
Android nativePackageId: com.reactlibrary
20-
platforms: bogus
21-
Apple tvosEnabled: false
22-
authorName: Your Name
23-
authorEmail: yourname@email.com
24-
author githubAccount: github_account
25-
license: MIT
26-
useAppleNetworking: false
15+
name: alice-bobbi
16+
full package name: react-native-alice-bobbi
17+
is view: false
18+
object class name: AliceBobbi
19+
Android nativePackageId: com.reactlibrary
20+
platforms: bogus
21+
Apple tvosEnabled: false
22+
authorName: Your Name
23+
authorEmail: yourname@email.com
24+
author githubAccount: github_account
25+
license: MIT
26+
useAppleNetworking: false
2727
",
2828
],
2929
},

tests/with-mocks/cli/command/action-func/with-logging/with-bogus-platforms/empty-string/__snapshots__/cli-command-with-empty-platforms-string.test.js.snap

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -12,18 +12,18 @@ Array [
1212
"info": Array [
1313
"CREATE new React Native module with the following options:
1414
15-
name: alice-bobbi
16-
full package name: react-native-alice-bobbi
17-
is view: false
18-
object class name: AliceBobbi
19-
Android nativePackageId: com.reactlibrary
20-
platforms:
21-
Apple tvosEnabled: false
22-
authorName: Your Name
23-
authorEmail: yourname@email.com
24-
author githubAccount: github_account
25-
license: MIT
26-
useAppleNetworking: false
15+
name: alice-bobbi
16+
full package name: react-native-alice-bobbi
17+
is view: false
18+
object class name: AliceBobbi
19+
Android nativePackageId: com.reactlibrary
20+
platforms:
21+
Apple tvosEnabled: false
22+
authorName: Your Name
23+
authorEmail: yourname@email.com
24+
author githubAccount: github_account
25+
license: MIT
26+
useAppleNetworking: false
2727
",
2828
],
2929
},

tests/with-mocks/cli/command/action-func/with-logging/with-error/__snapshots__/cli-command-with-logging-with-error.test.js.snap

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -12,18 +12,18 @@ Array [
1212
"info": Array [
1313
"CREATE new React Native module with the following options:
1414
15-
name: alice-bobbi
16-
full package name: react-native-alice-bobbi
17-
is view: false
18-
object class name: AliceBobbi
19-
Android nativePackageId: com.reactlibrary
20-
platforms: android,ios
21-
Apple tvosEnabled: false
22-
authorName: Your Name
23-
authorEmail: yourname@email.com
24-
author githubAccount: github_account
25-
license: MIT
26-
useAppleNetworking: false
15+
name: alice-bobbi
16+
full package name: react-native-alice-bobbi
17+
is view: false
18+
object class name: AliceBobbi
19+
Android nativePackageId: com.reactlibrary
20+
platforms: android,ios
21+
Apple tvosEnabled: false
22+
authorName: Your Name
23+
authorEmail: yourname@email.com
24+
author githubAccount: github_account
25+
license: MIT
26+
useAppleNetworking: false
2727
",
2828
],
2929
},

tests/with-mocks/cli/program/with-example/with-logging/__snapshots__/cli-program-with-example-with-logging.test.js.snap

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -206,24 +206,24 @@ Array [
206206
"info": Array [
207207
"CREATE new React Native module with the following options:
208208
209-
name: test-package
210-
full package name: react-native-test-package
211-
is view: false
212-
object class name: TestPackage
213-
Android nativePackageId: com.reactlibrary
214-
platforms: android,ios
215-
Apple tvosEnabled: false
216-
authorName: Your Name
217-
authorEmail: yourname@email.com
218-
author githubAccount: github_account
219-
license: MIT
220-
useAppleNetworking: false
221-
222-
generateExample: true
223-
exampleFileLinkage: false
224-
exampleName: example
225-
exampleReactNativeTemplate: react-native@latest
226-
writeExamplePodfile: false
209+
name: test-package
210+
full package name: react-native-test-package
211+
is view: false
212+
object class name: TestPackage
213+
Android nativePackageId: com.reactlibrary
214+
platforms: android,ios
215+
Apple tvosEnabled: false
216+
authorName: Your Name
217+
authorEmail: yourname@email.com
218+
author githubAccount: github_account
219+
license: MIT
220+
useAppleNetworking: false
221+
222+
generateExample: true
223+
exampleFileLinkage: false
224+
exampleName: example
225+
exampleReactNativeTemplate: react-native@latest
226+
writeExamplePodfile: false
227227
",
228228
],
229229
},

tests/with-mocks/lib/create/with-example/with-logging/with-defaults/__snapshots__/create-with-example-with-defaults.test.js.snap

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -12,24 +12,24 @@ Array [
1212
"info": Array [
1313
"CREATE new React Native module with the following options:
1414
15-
name: alice-bobbi
16-
full package name: react-native-alice-bobbi
17-
is view: false
18-
object class name: AliceBobbi
19-
Android nativePackageId: com.reactlibrary
20-
platforms: android,ios
21-
Apple tvosEnabled: false
22-
authorName: Your Name
23-
authorEmail: yourname@email.com
24-
author githubAccount: github_account
25-
license: MIT
26-
useAppleNetworking: false
27-
28-
generateExample: true
29-
exampleFileLinkage: false
30-
exampleName: example
31-
exampleReactNativeTemplate: react-native@latest
32-
writeExamplePodfile: false
15+
name: alice-bobbi
16+
full package name: react-native-alice-bobbi
17+
is view: false
18+
object class name: AliceBobbi
19+
Android nativePackageId: com.reactlibrary
20+
platforms: android,ios
21+
Apple tvosEnabled: false
22+
authorName: Your Name
23+
authorEmail: yourname@email.com
24+
author githubAccount: github_account
25+
license: MIT
26+
useAppleNetworking: false
27+
28+
generateExample: true
29+
exampleFileLinkage: false
30+
exampleName: example
31+
exampleReactNativeTemplate: react-native@latest
32+
writeExamplePodfile: false
3333
",
3434
],
3535
},

tests/with-mocks/lib/create/with-example/with-logging/with-error/__snapshots__/with-yarn-error-logging.test.js.snap

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -12,24 +12,24 @@ Array [
1212
"info": Array [
1313
"CREATE new React Native module with the following options:
1414
15-
name: alice-bobbi
16-
full package name: react-native-alice-bobbi
17-
is view: false
18-
object class name: AliceBobbi
19-
Android nativePackageId: com.reactlibrary
20-
platforms: android,ios
21-
Apple tvosEnabled: false
22-
authorName: Your Name
23-
authorEmail: yourname@email.com
24-
author githubAccount: github_account
25-
license: MIT
26-
useAppleNetworking: false
27-
28-
generateExample: true
29-
exampleFileLinkage: false
30-
exampleName: example
31-
exampleReactNativeTemplate: react-native@latest
32-
writeExamplePodfile: false
15+
name: alice-bobbi
16+
full package name: react-native-alice-bobbi
17+
is view: false
18+
object class name: AliceBobbi
19+
Android nativePackageId: com.reactlibrary
20+
platforms: android,ios
21+
Apple tvosEnabled: false
22+
authorName: Your Name
23+
authorEmail: yourname@email.com
24+
author githubAccount: github_account
25+
license: MIT
26+
useAppleNetworking: false
27+
28+
generateExample: true
29+
exampleFileLinkage: false
30+
exampleName: example
31+
exampleReactNativeTemplate: react-native@latest
32+
writeExamplePodfile: false
3333
",
3434
],
3535
},

tests/with-mocks/lib/create/with-example/with-logging/with-options/__snapshots__/create-with-example-with-options.test.js.snap

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -6,24 +6,24 @@ Array [
66
"info": Array [
77
"CREATE new React Native module with the following options:
88
9-
name: alice-bobbi
10-
full package name: react-native-alice-bobbi
11-
is view: false
12-
object class name: AliceBobbi
13-
Android nativePackageId: com.alicebits
14-
platforms: android,ios
15-
Apple tvosEnabled: true
16-
authorName: Alice
17-
authorEmail: contact@alice.me
18-
author githubAccount: alicebits
19-
license: ISC
20-
useAppleNetworking: false
21-
22-
generateExample: true
23-
exampleFileLinkage: true
24-
exampleName: demo
25-
exampleReactNativeTemplate: react-native@npm:react-native-tvos
26-
writeExamplePodfile: false
9+
name: alice-bobbi
10+
full package name: react-native-alice-bobbi
11+
is view: false
12+
object class name: AliceBobbi
13+
Android nativePackageId: com.alicebits
14+
platforms: android,ios
15+
Apple tvosEnabled: true
16+
authorName: Alice
17+
authorEmail: contact@alice.me
18+
author githubAccount: alicebits
19+
license: ISC
20+
useAppleNetworking: false
21+
22+
generateExample: true
23+
exampleFileLinkage: true
24+
exampleName: demo
25+
exampleReactNativeTemplate: react-native@npm:react-native-tvos
26+
writeExamplePodfile: false
2727
",
2828
],
2929
},

0 commit comments

Comments
 (0)