{"name":"get-current-version","repository":{"type":"git","url":"git+https://github.com/fabiospampinato/get-current-version.git"},"description":"Get the version of the currently executing bin.","license":"MIT","version":"1.0.2","type":"module","main":"dist/index.js","exports":"./dist/index.js","types":"./dist/index.d.ts","scripts":{"clean":"tsex clean","compile":"tsex compile","compile:watch":"tsex compile --watch","test":"tsex test","test:watch":"tsex test --watch","prepublishOnly":"tsex prepare"},"keywords":["cli","get","current","version"],"dependencies":{"get-current-package":"^1.0.1"},"devDependencies":{"fava":"^0.3.4","tsex":"^4.0.2","typescript":"^5.7.3"},"_id":"get-current-version@1.0.2","gitHead":"67174b20341208a347fe1e6d2d2054228ade6d5c","bugs":{"url":"https://github.com/fabiospampinato/get-current-version/issues"},"homepage":"https://github.com/fabiospampinato/get-current-version#readme","_nodeVersion":"18.19.0","_npmVersion":"10.2.3","dist":{"integrity":"sha512-tf4mFvbeZjNvaEzwJlZXOi8ySpVCZmcZJS8hNFnh2d345e2t2rrTaZ/7QBwU4HfruShJ5+O1ObLJc0JSdaYo7g==","shasum":"d63bc696bd9de405acbc87defe0d3ab87a6bbaf8","tarball":"http://registry-npm.ywwl.com/get-current-version/download/get-current-version-1.0.2.tgz","fileCount":5,"unpackedSize":3082,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDRFGLmUNTNXtFZgEOrmUyOKUnEcdLjH7YT+0DwCWgxFQIhAIsXJY7OJfhWLgPNH0z3lpY9XtkZ1f7yf/02jcgegIHY"}],"size":1704,"noattachment":false,"key":"/get-current-version/-/get-current-version-1.0.2.tgz"},"_npmUser":{"name":"fabiospampinato","email":"spampinabio@gmail.com"},"directories":{},"maintainers":[{"name":"fabiospampinato","email":"spampinabio@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/get-current-version_1.0.2_1736707824217_0.9138492092463928"},"_hasShrinkwrap":false,"readme":"# Get Current Version\n\nGet the version of the currently executing bin.\n\nThis is meant to be used in combination with [`tiny-updater`](https://github.com/fabiospampinato/tiny-updater) or similar, in order to get the version of the currently executing bin very conveniently, without importing a \"package.json\" and without hard-coding the version number yourself.\n\nSee [`get-current-package`](https://github.com/fabiospampinato/get-current-package) for a more general version of this package.\n\n## Install\n\n```sh\nnpm install get-current-version\n```\n\n## Usage\n\nYou should have something like this in your bin app:\n\n```ts\nimport getCurrentVersion from 'get-current-version';\n\nconsole.log ( getCurrentVersion () ); // 1.0.0\n```\n\nThen executing the bin would produce this:\n\n```\n> my-bin\n< 1.0.0\n```\n\nBasically it detects which entrypoint file is being executed and retrieves its version.\n\n## License\n\nMIT © Fabio Spampinato\n","publish_time":1736707824389,"_cnpm_publish_time":1736707824389,"dist-tags":{"latest":"1.0.2"}}