Skip to content

Commit

Permalink
🎉 Feat(app): add new init command to create config file!
Browse files Browse the repository at this point in the history
  • Loading branch information
INeedJobToStartWork committed Jan 16, 2024
1 parent 89db0fc commit 715c792
Show file tree
Hide file tree
Showing 15 changed files with 321 additions and 82 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# commitsmile

## 0.4.0

### Minor Changes

- Add `init` command function!

## 0.3.10

### Patch Changes
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,10 @@ If Path:
- do not include filename it will use standard process to find.
- include - will just check this file (faster way)

<!-- ### Init config
### Init config

to init config we use optional paremeter `--init`:
to init config we use `init`:

```bash copy
npm run commitSmile --init
``` -->
npm run commitSmile init
```
7 changes: 7 additions & 0 deletions config/webpack/webpack.base.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
import CopyPlugin from "copy-webpack-plugin";
import path from "path";

const __dirname = path.resolve();
const PATHOUT = path.resolve(__dirname, "lib");

export default {
entry: {
Expand Down Expand Up @@ -36,5 +38,10 @@ export default {
"@": path.resolve(__dirname, "src/")
}
},
plugins: [
new CopyPlugin({
patterns: [{ from: path.resolve(__dirname, "./src/templates"), to: path.join(PATHOUT, "templates") }]
})
],
target: "node"
};
3 changes: 2 additions & 1 deletion config/webpack/webpack.prod.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@ export default merge(webpackBaseConfig, {
new CopyPlugin({
patterns: [
{ from: path.resolve(__dirname, "README.md"), to: PATHOUT },
{ from: path.resolve(__dirname, "package.json"), to: PATHOUT }
{ from: path.resolve(__dirname, "package.json"), to: PATHOUT },
{ from: path.resolve(__dirname, "./src/templates"), to: path.join(PATHOUT, "templates") }
]
})
],
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "commitsmile",
"version": "0.3.10",
"version": "0.4.0",
"description": "Make smile on your commits",
"keywords": [],
"homepage": "",
Expand Down Expand Up @@ -66,6 +66,7 @@
"eslint-plugin-sort-keys-fix": "^1.1.2",
"globals": "^13.24.0",
"husky": "^8.0.3",
"jsdoc": "^4.0.2",
"lint-staged": "^15.2.0",
"prettier": "^3.1.1",
"prettier-plugin-packagejson": "^2.4.8",
Expand Down
161 changes: 161 additions & 0 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 715c792

Please sign in to comment.