diff --git a/package.json b/package.json index e16b07fb8..658a43825 100644 --- a/package.json +++ b/package.json @@ -6,7 +6,8 @@ "types": "dist/index.d.ts", "bin": { "ts-node": "dist/bin.js", - "ts-script": "dist/bin-script.js", + "ts-script": "dist/bin-script-deprecated.js", + "ts-node-script": "dist/bin-script.js", "ts-node-transpile-only": "dist/bin-transpile.js" }, "files": [ diff --git a/src/bin-script-deprecated.ts b/src/bin-script-deprecated.ts new file mode 100644 index 000000000..6c0dc6f82 --- /dev/null +++ b/src/bin-script-deprecated.ts @@ -0,0 +1,10 @@ +#!/usr/bin/env node + +import { main } from './bin' + +console.warn( + 'ts-script has been deprecated and will be removed in the next major release.', + 'Please use ts-node-script instead' +) + +main(['--script-mode', ...process.argv.slice(2)])