1 | const { shellSync } = require('execa')
|
2 | const { warning } = require('./tip')
|
3 | module.exports = function() {
|
4 | try {
|
5 | shellSync('yarnpkg --version', { stdio: 'ignore' })
|
6 | return true
|
7 | } catch (e) {
|
8 | warning(
|
9 | '检测到未安装 Yarn 建议安装 https://yarn.bootcss.com/docs/install/#windows-stable'
|
10 | )
|
11 | return false
|
12 | }
|
13 | }
|