Skip to content

Commit

Permalink
When publishing a package, copy README from root folder.
Browse files Browse the repository at this point in the history
  • Loading branch information
molefrog committed Feb 26, 2024
1 parent 8971676 commit f36fa22
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 6 deletions.
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,7 @@ tsconfig.vitest-temp.json
# type definitions in the project root are copied from types/ folder
# before publishing, so they should be ignored
/*.d.ts

# README is copied from the root folder
packages/wouter/README.md
packages/wouter-preact/README.md
4 changes: 2 additions & 2 deletions package-lock.json

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

5 changes: 4 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,10 @@
"lint-types": "vitest typecheck"
},
"author": "Alexey Taktarov <molefrog@gmail.com>",
"repository": "molefrog/wouter",
"repository": {
"type": "git",
"url": "git+https://github.com/molefrog/wouter.git"
},
"license": "ISC",
"prettier": {
"tabWidth": 2,
Expand Down
8 changes: 6 additions & 2 deletions packages/wouter-preact/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,14 @@
},
"scripts": {
"build": "rollup -c",
"watch": "rollup -c -w"
"watch": "rollup -c -w",
"prepublishOnly": "npm run build && cp ../../README.md ."
},
"author": "Alexey Taktarov <molefrog@gmail.com>",
"repository": "molefrog/wouter",
"repository": {
"type": "git",
"url": "git+https://github.com/molefrog/wouter.git"
},
"license": "Unlicense",
"peerDependencies": {
"preact": "^10.0.0"
Expand Down
3 changes: 2 additions & 1 deletion packages/wouter/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,8 @@
},
"scripts": {
"build": "rollup -c",
"watch": "rollup -c -w"
"watch": "rollup -c -w",
"prepublishOnly": "npm run build && cp ../../README.md ."
},
"author": "Alexey Taktarov <molefrog@gmail.com>",
"repository": {
Expand Down

0 comments on commit f36fa22

Please sign in to comment.