nero-init 1.0.6 → 1.0.7
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.
- package/README.md +3 -3
- package/dist/index.js +2 -2
- package/dist/install.js +1 -1
- package/dist/templates/cli/tests/cli.test.ts +4 -5
- package/dist/templates/library/eslint.config.js +18 -18
- package/dist/templates/library/src/index.ts +1 -3
- package/dist/templates/library/tests/lib.test.ts +1 -1
- package/package.json +1 -1
- package/dist/templates/library/src/lib/index.ts +0 -1
package/README.md
CHANGED
|
@@ -42,9 +42,9 @@ No arguments, no flags — just answer the prompts.
|
|
|
42
42
|
├── .prettierrc # Prettier configuration
|
|
43
43
|
├── .prettierignore # Prettier ignore rules
|
|
44
44
|
│
|
|
45
|
-
├── eslint.config.
|
|
45
|
+
├── eslint.config.js # ESLint configuration
|
|
46
46
|
├── tsconfig.json # TypeScript configuration
|
|
47
|
-
├── vitest.config.
|
|
47
|
+
├── vitest.config.ys # Test configuration
|
|
48
48
|
│
|
|
49
49
|
├── package.json # Package metadata & scripts
|
|
50
50
|
├── README.md # Project documentation
|
|
@@ -68,7 +68,7 @@ No arguments, no flags — just answer the prompts.
|
|
|
68
68
|
├── .prettierrc # Prettier configuration
|
|
69
69
|
├── .prettierignore # Prettier ignore rules
|
|
70
70
|
│
|
|
71
|
-
├── eslint.config.
|
|
71
|
+
├── eslint.config.js # ESLint (flat, TypeScript config)
|
|
72
72
|
├── tsconfig.json # TypeScript configuration
|
|
73
73
|
├── vitest.config.ts # Test configuration
|
|
74
74
|
│
|
package/dist/index.js
CHANGED
|
@@ -6,7 +6,7 @@ import { postInstall } from './install.js';
|
|
|
6
6
|
async function run() {
|
|
7
7
|
const answers = await promptUser();
|
|
8
8
|
const template = await selectTemplate(answers);
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
await renderTemplate(template, answers);
|
|
10
|
+
await postInstall(template, answers);
|
|
11
11
|
}
|
|
12
12
|
await run();
|
package/dist/install.js
CHANGED
|
@@ -74,7 +74,7 @@ async function initGit(dir) {
|
|
|
74
74
|
console.log(chalk.hex(theme.muted)(` ${symbols.corner} No git binary found`));
|
|
75
75
|
}
|
|
76
76
|
}
|
|
77
|
-
catch
|
|
77
|
+
catch {
|
|
78
78
|
spinner.stopAndPersist({
|
|
79
79
|
symbol: chalk.hex('#EF4444')(`${symbols.error}`),
|
|
80
80
|
text: chalk.hex('#EF4444')('Failed to initialize git'),
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
import { describe, it, expect } from 'vitest'
|
|
2
|
-
import { run } from '../src/index.js'
|
|
3
2
|
|
|
4
|
-
describe('cli
|
|
5
|
-
it('
|
|
6
|
-
const
|
|
7
|
-
expect(
|
|
3
|
+
describe('cli module', () => {
|
|
4
|
+
it('can be imported without throwing', async () => {
|
|
5
|
+
const mod = await import('../src/cli/options.js')
|
|
6
|
+
expect(mod).toBeDefined()
|
|
8
7
|
})
|
|
9
8
|
})
|
|
@@ -1,40 +1,40 @@
|
|
|
1
|
-
import tseslint from
|
|
2
|
-
import parser from
|
|
1
|
+
import tseslint from '@typescript-eslint/eslint-plugin'
|
|
2
|
+
import parser from '@typescript-eslint/parser'
|
|
3
3
|
|
|
4
4
|
export default [
|
|
5
5
|
{
|
|
6
|
-
ignores: [
|
|
6
|
+
ignores: ['dist/**', 'node_modules/**', 'assets/**'],
|
|
7
7
|
},
|
|
8
8
|
{
|
|
9
|
-
files: [
|
|
9
|
+
files: ['**/*.ts'],
|
|
10
10
|
|
|
11
11
|
languageOptions: {
|
|
12
12
|
parser,
|
|
13
13
|
parserOptions: {
|
|
14
|
-
ecmaVersion:
|
|
15
|
-
sourceType:
|
|
14
|
+
ecmaVersion: 'latest',
|
|
15
|
+
sourceType: 'module',
|
|
16
16
|
},
|
|
17
17
|
},
|
|
18
18
|
plugins: {
|
|
19
|
-
|
|
19
|
+
'@typescript-eslint': tseslint,
|
|
20
20
|
},
|
|
21
21
|
rules: {
|
|
22
22
|
// correctness
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
{ argsIgnorePattern:
|
|
23
|
+
'no-unused-vars': 'off',
|
|
24
|
+
'@typescript-eslint/no-unused-vars': [
|
|
25
|
+
'error',
|
|
26
|
+
{ argsIgnorePattern: '^_' },
|
|
27
27
|
],
|
|
28
28
|
|
|
29
|
-
|
|
30
|
-
|
|
29
|
+
'no-shadow': 'off',
|
|
30
|
+
'@typescript-eslint/no-shadow': 'error',
|
|
31
31
|
|
|
32
|
-
|
|
33
|
-
|
|
32
|
+
'no-redeclare': 'off',
|
|
33
|
+
'@typescript-eslint/no-redeclare': 'error',
|
|
34
34
|
|
|
35
35
|
// sanity
|
|
36
|
-
|
|
37
|
-
|
|
36
|
+
'no-console': 'error',
|
|
37
|
+
'prefer-const': 'error',
|
|
38
38
|
},
|
|
39
39
|
},
|
|
40
|
-
]
|
|
40
|
+
]
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export const LIB_NAME = 'library'
|