UNPKG
yarn-or-die
Version:
latest (1.1.0)
1.1.0
1.0.0
Force using yarn instead of npm
github.com/glenngr/yarn-or-die
glenngr/yarn-or-die
yarn-or-die
/
index.js
10 lines
(6 loc)
•
222 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
9
10
#!/usr/bin/env node
const
usingYarn = process.
env
.
npm_config_user_agent
.
indexOf
(
'yarn'
) !== -
1
;
if
(!usingYarn) {
throw
new
Error
(
'You have to use Yarn instead of NPM for this command'
); } process.
exit
(
0
);