{"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.","version":"1.0.1","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.0"},"devDependencies":{"fava":"^0.1.0","tsex":"^2.1.0","typescript":"^4.9.5"},"gitHead":"a4e446f77024693394c32c8080709e46765b7371","bugs":{"url":"https://github.com/fabiospampinato/get-current-version/issues"},"homepage":"https://github.com/fabiospampinato/get-current-version#readme","_id":"get-current-version@1.0.1","_nodeVersion":"18.12.0","_npmVersion":"8.19.2","dist":{"integrity":"sha512-81cAoom+eMvmIsUY64nVs3Aec366pN3Lnd1ptr8NjtmgCAkzrgqfBeG/c7DeQK0jpIBkjaGpYLdDpHzsM1TJwQ==","shasum":"65f6594b2d052eefb735d56d0b0fbda4975dae32","tarball":"http://registry-npm.ywwl.com/get-current-version/download/get-current-version-1.0.1.tgz","fileCount":9,"unpackedSize":3682,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDcCrZFr4MHpb0hgwNRWPfjL9uAf6lKVu9b/FrZBVo+PwIhAKPPJYDEtxWlYFytFIpugJxLzR1l3OpiHDHuav2Xk0Z6"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJj5xBUACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmq0gA/+MDxpjVhcM/Np87lhiqkdnefVImTTKgjKXecspjx/rE+Sr/jD\r\nuRFUi2TP199BQU9KjAc0wkTVTjmYfgZTkqGTWKdabJdViclc39pPuH/QwwbQ\r\nsU8AC6Wwjsu0CMxAKeLgarpubufMw9coPB+KrL4LWe40RH8awHBk4xwQJXzw\r\nXUpzTHf9CpxsuRkez0/i/RE7+fvKtiivRbs40ywkD+8tBTlgpgXHP6O4l1Bj\r\nkQOyF85plR2mXdGETOrb6i85jQIBrgvGAVq1XAUMHDXN+9vLXjGY+1wfWvH7\r\nkg+4wHc609L9OAKs8cxa+y0cD5gbbMUJBMHON+eN0cUuPNV1ywjqPDi2OQBe\r\ngyp4w+/Ple4dA4298OrJWfNMIHWXUZcnXxkooDskxe/SaCU2Gx+QMhelyNB5\r\nPg7YWlk37ZlgXGap9YqlsH+frzZy5yJ6UKr6w9IQNqpcH5Ew2Q0nnujMrFm5\r\nG2Bjlob+7RN9PVWSOXGANarrXA0AE0bQ3S6f3jwmwFrx7v2599pu2LsgyV+X\r\n+W3ve3mNYsUyeez5hBOvH7kJK6C+PK69UuXvdciCcku/8INZKYXzFLDRIL+H\r\nftqUbDENb55kDZuklB87PFxgq8VDY/n7csbcnNchXQtU9ngoUnCuBw8funLA\r\n36AIxbrt+wbzV5FfEI/kDLuZAkIhMyqwLfs=\r\n=LNsf\r\n-----END PGP SIGNATURE-----\r\n","size":2017,"noattachment":false,"key":"/get-current-version/-/get-current-version-1.0.1.tgz"},"_npmUser":{"name":"fabiospampinato","email":"spampinabio@gmail.com"},"directories":{},"maintainers":[{"name":"fabiospampinato","email":"spampinabio@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/get-current-version_1.0.1_1676087380529_0.830026984557634"},"_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\n## Install\n\n```sh\nnpm install --save 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":1676087380750,"_cnpm_publish_time":1676087380750,"dist-tags":{"latest":"1.0.2"}}