You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+17-29Lines changed: 17 additions & 29 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,57 +10,45 @@ An [npm initializer][npm/init] to scaffold a node project and include basic tool
10
10
11
11
## Requirements
12
12
13
-
-`npm >= x.x`
14
-
-`node >= x.x`
13
+
-`npm >= 6.5`
14
+
-`node >= 10.9`
15
15
16
16
## Usage
17
17
18
-
`npm init node-project path/to/project [params]`
18
+
`npm init node-project path/to/project`
19
19
20
-
## Params
20
+
## What it does
21
21
22
-
### Project path
23
-
24
-
`npm init node-project path/to/project [params]`
25
-
26
-
Will create a new folder for the project in the specified path.
22
+
1. Create the folder for the new project
23
+
1. Guide you through a questionnarie to setup the project
24
+
2. Initialize a git repo
25
+
3. Copy the template files (src, eslintrc, gitignore, readme, etc)
26
+
4. Can create a Github repository
27
+
5. Install eslint
28
+
5. Install the selected testing dependencies
29
+
6. Generate package.json with all the project details
30
+
7. Commit and push the initial commit
27
31
28
32
## About this package
29
33
30
34
So, this started as a dry thing.
31
-
I'm not super expert with NodeJS, but every time that I start a new project, I hate to go to other project, copy files like eslintrc, editorconfig, install the same dependencies, create folder structure, etc.
35
+
I'm not expert with NodeJS, but every time that I start a new project, I hate to go to other project, copy files like eslintrc, editorconfig, install the same dependencies, create folder structure, etc.
32
36
So, the idea is to have a create package to use it in the form of:
33
-
`npm init node-project a-demo-project`
37
+
`npm init node-project path/to/project`
34
38
and with this have a new folder my-new-project with everything ready to work.
35
39
36
40
I know there are a lot of similar packages out there, but the idea is to learn more about nodejs api, handling files, packages, etc.
37
41
38
-
So far, what this package will do (already does) is:
39
-
1. Create the folder for the new project
40
-
2. Create a git repo
41
-
3. Copy the structure for files (src, and root files like eslintrc, gitignore, readme, etc)
42
-
4. Create a github repository
43
-
5. Install eslint and jest dependencies
44
-
6. Update package.json
45
-
7. Commit and push the initial commit
42
+
## Future features
46
43
47
-
What I have in my TODO list:
48
44
1. Fix the structure of modules, classes and etc
49
-
2.~~Avoid as much dependencies as possible~~
50
-
3.~~Understand about the difference for eslint airbnb and eslint plugin node~~
51
45
4. Add unit testing
52
-
5.~~Improve the calls for shell (right now is with exec, but I need to use spawn in order to have the stdout inherit, but that mess with the sync method and the responses)~~
53
-
6.~~Add documentation for classes, modules and methods~~
54
46
7. Add options to create the project with params instead of questionnaire
55
-
8.~~Add questionnaire for the creation~~
56
-
9. Publish the npm package
57
47
10. Add a good error handler
58
48
11. Color for the console messages
59
49
12. Modify template structure (the one that is generated in the new project) to include unit test
60
50
13. Include license files to the template copy/update process
61
51
14. A logger ? (just for learning)
62
-
15.~~CWD for git commands~~
63
-
16. Best place for the auth.json
64
52
17. Ability to handle auth for different github accounts
65
53
18. Option to questionnaire with all the default values
66
54
@@ -99,7 +87,7 @@ If you are planning to allow this script to create your github repositories, is
0 commit comments