Skip to content
This repository has been archived by the owner on Nov 4, 2024. It is now read-only.

Commit

Permalink
fix: use manifest bin field for rvg bin (#293)
Browse files Browse the repository at this point in the history
  • Loading branch information
noahnu authored Mar 26, 2023
1 parent dadd471 commit 06c3091
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 5 deletions.
2 changes: 0 additions & 2 deletions packages/cli/bin/rvg

This file was deleted.

9 changes: 7 additions & 2 deletions packages/cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,10 @@
"homepage": "https://github.com/tophat/react-vector-graphics#readme",
"license": "Apache-2.0",
"main": "src/index.ts",
"bin": {
"rvg": "src/bin.ts"
},
"files": [
"bin",
"lib"
],
"repository": {
Expand All @@ -24,7 +26,10 @@
"publishConfig": {
"access": "public",
"registry": "https://registry.npmjs.org/",
"main": "lib/index.js"
"main": "lib/index.js",
"bin": {
"rvg": "lib/bin.js"
}
},
"dependencies": {
"@react-vector-graphics/core": "workspace:^0.4.2",
Expand Down
3 changes: 3 additions & 0 deletions packages/cli/src/bin.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import run from './index'

run()
1 change: 0 additions & 1 deletion packages/core/src/main.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// eslint-disable-next-line prettier/prettier
import { type Config as CoreConfig, loadConfig } from '@svgr/core'

import { getLogger } from './logging'
Expand Down
2 changes: 2 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1678,6 +1678,8 @@ __metadata:
fs-extra: ^9.0.0
memfs: ^3.1.1
yargs: ^16.0.3
bin:
rvg: src/bin.ts
languageName: unknown
linkType: soft

Expand Down

0 comments on commit 06c3091

Please sign in to comment.