我正在尝试运行Koel并运行需要运行项目的每个命令。
我阅读了文档,这是安装的一部分。
$ cd <PUBLIC_WEB_DIRECTORY_FOR_KOEL>
$ git clone --recurse-submodules https://github.com/phanan/koel.git .
$ git checkout v4.0.0 # Check out the latest version at https://github.com/phanan/koel/releases
$ composer install
$ php artisan koel:init # Populate credentials during the process
$ php artisan serve
执行php artisan koel:init
命令后,出现以下错误:
yarn install v1.19.1
[1/4] Resolving packages...
[2/4] Fetching packages...
info fsevents@1.2.4: The platform "win32" is incompatible with this module.
info "fsevents@1.2.4" is an optional dependency and failed compatibility check. Excluding it from installation.
info fsevents@1.1.3: The platform "win32" is incompatible with this module.
info "fsevents@1.1.3" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
warning " > eslint-config-vue@2.0.2" has incorrect peer dependency "eslint@^2.0.0 || ^3.0.0".
warning " > eslint-plugin-vue@2.1.0" has incorrect peer dependency "eslint@^2.0.0 || ^3.0.0 || ^4.0.0".
[4/4] Building fresh packages...
error C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\node-sass: Command failed.
Exit code: 1
Command: node scripts/build.js
Arguments:
Directory: C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\node-sass
Output:
Building: C:\Program Files\nodejs\node.exe C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\node-gyp\bin\node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
gyp info it worked if it ends with ok
gyp verb cli [
gyp verb cli 'C:\\Program Files\\nodejs\\node.exe',
gyp verb cli 'C:\\Users\\ramtin\\Desktop\\koel\\resources\\assets\\node_modules\\node-gyp\\bin\\node-gyp.js',
gyp verb cli 'rebuild',
gyp verb cli '--verbose',
gyp verb cli '--libsass_ext=',
gyp verb cli '--libsass_cflags=',
gyp verb cli '--libsass_ldflags=',
gyp verb cli '--libsass_library='
gyp verb cli ]
gyp info using node-gyp@3.8.0
gyp info using node@12.2.0 | win32 | x64
gyp verb command rebuild []
gyp verb command clean []
gyp verb clean removing "build" directory
gyp verb command configure []
gyp verb check python checking for Python executable "python2" in the PATH
gyp verb `which` failed Error: not found: python2
gyp verb `which` failed at getNotFoundError (C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\which\which.js:13:12)
gyp verb `which` failed at F (C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\which\which.js:68:19)
gyp verb `which` failed at E (C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\which\which.js:80:29)
gyp verb `which` failed at C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\which\which.js:89:16
gyp verb `which` failed at C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\isexe\index.js:42:5
gyp verb `which` failed at C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\isexe\windows.js:36:5
gyp verb `which` failed at FSReqCallback.oncomplete (fs.js:148:21)
gyp verb `which` failed python2 Error: not found: python2
gyp verb `which` failed at getNotFoundError (C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\which\which.js:13:12)
gyp verb `which` failed at F (C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\which\which.js:68:19)
gyp verb `which` failed at E (C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\which\which.js:80:29)
gyp verb `which` failed at C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\which\which.js:89:16
gyp verb `which` failed at C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\isexe\index.js:42:5
gyp verb `which` failed at C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\isexe\windows.js:36:5
gyp verb `which` failed at FSReqCallback.oncomplete (fs.js:148:21) {
gyp verb `which` failed stack: 'Error: not found: python2\n at getNotFoundError ' +
gyp verb `which` failed '(C:\\Users\\ramtin\\Desktop\\koel\\resources\\assets\\node_modules\\which\\which.js:13:12)\n' +
gyp verb `which` failed ' at F ' +
gyp verb `which` failed '(C:\\Users\\ramtin\\Desktop\\koel\\resources\\assets\\node_modules\\which\\which.js:68:19)\n' +
gyp verb `which` failed ' at E ' +
gyp verb `which` failed '(C:\\Users\\ramtin\\Desktop\\koel\\resources\\assets\\node_modules\\which\\which.js:80:29)\n' +
gyp verb `which` failed ' at ' +
gyp verb `which` failed 'C:\\Users\\ramtin\\Desktop\\koel\\resources\\assets\\node_modules\\which\\which.js:89:16\n' +
gyp verb `which` failed ' at ' +
gyp verb `which` failed 'C:\\Users\\ramtin\\Desktop\\koel\\resources\\assets\\node_modules\\isexe\\index.js:42:5\n' +
gyp verb `which` failed ' at ' +
gyp verb `which` failed 'C:\\Users\\ramtin\\Desktop\\koel\\resources\\assets\\node_modules\\isexe\\windows.js:36:5\n' +
gyp verb `which` failed ' at FSReqCallback.oncomplete (fs.js:148:21)',
gyp verb `which` failed code: 'ENOENT'
gyp verb `which` failed }
gyp verb check python checking for Python executable "python" in the PATH
gyp verb `which` failed Error: not found: python
gyp verb `which` failed at getNotFoundError (C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\which\which.js:13:12)
gyp verb `which` failed at F (C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\which\which.js:68:19)
gyp verb `which` failed at E (C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\which\which.js:80:29)
gyp verb `which` failed at C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\which\which.js:89:16
gyp verb `which` failed at C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\isexe\index.js:42:5
gyp verb `which` failed at C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\isexe\windows.js:36:5
gyp verb `which` failed at FSReqCallback.oncomplete (fs.js:148:21)
gyp verb `which` failed python Error: not found: python
gyp verb `which` failed at getNotFoundError (C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\which\which.js:13:12)
gyp verb `which` failed at F (C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\which\which.js:68:19)
gyp verb `which` failed at E (C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\which\which.js:80:29)
gyp verb `which` failed at C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\which\which.js:89:16
gyp verb `which` failed at C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\isexe\index.js:42:5
gyp verb `which` failed at C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\isexe\windows.js:36:5
gyp verb `which` failed at FSReqCallback.oncomplete (fs.js:148:21) {
gyp verb `which` failed stack: 'Error: not found: python\n at getNotFoundError ' +
gyp verb `which` failed '(C:\\Users\\ramtin\\Desktop\\koel\\resources\\assets\\node_modules\\which\\which.js:13:12)\n' +
gyp verb `which` failed ' at F ' +
gyp verb `which` failed '(C:\\Users\\ramtin\\Desktop\\koel\\resources\\assets\\node_modules\\which\\which.js:68:19)\n' +
gyp verb `which` failed ' at E ' +
gyp verb `which` failed '(C:\\Users\\ramtin\\Desktop\\koel\\resources\\assets\\node_modules\\which\\which.js:80:29)\n' +
gyp verb `which` failed ' at ' +
gyp verb `which` failed 'C:\\Users\\ramtin\\Desktop\\koel\\resources\\assets\\node_modules\\which\\which.js:89:16\n' +
gyp verb `which` failed ' at ' +
gyp verb `which` failed 'C:\\Users\\ramtin\\Desktop\\koel\\resources\\assets\\node_modules\\isexe\\index.js:42:5\n' +
gyp verb `which` failed ' at ' +
gyp verb `which` failed 'C:\\Users\\ramtin\\Desktop\\koel\\resources\\assets\\node_modules\\isexe\\windows.js:36:5\n' +
gyp verb `which` failed ' at FSReqCallback.oncomplete (fs.js:148:21)',
gyp verb `which` failed code: 'ENOENT'
gyp verb `which` failed }
gyp verb could not find "python". checking python launcher
gyp verb could not find "python". guessing location
gyp verb ensuring that file exists: C:\Python27\python.exe
gyp ERR! configure error
gyp ERR! stack Error: Can't find Python executable "python", you can set the PYTHON env variable.
gyp ERR! stack at PythonFinder.failNoPython (C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\node-gyp\lib\configure.js:484:19)
gyp ERR! stack at PythonFinder.<anonymous> (C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\node-gyp\lib\configure.js:509:16)
gyp ERR! stack at callback (C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\graceful-fs\polyfills.js:289:20)
gyp ERR! stack at FSReqCallback.oncomplete (fs.js:148:21)
gyp ERR! System Windows_NT 10.0.18362
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\ramtin\\Desktop\\koel\\resources\\assets\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
gyp ERR! cwd C:\Users\ramtin\Desktop\koel\resources\assets\node_modules\node-sass
gyp ERR! node -v v12.2.0
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
Build failed with error code: 1
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
Oops! Koel installation or upgrade didn't finish successfully.
Please try again, or visit https://koel.phanan.net/docs for manual installation.
? Sorry for this. You deserve better.
我阅读错误并在互联网(GitHub和...)上搜索,但找不到任何东西。
答案 0 :(得分:0)
显然,koel资产的主分支位于单独的存储库中。 以递归方式克隆存储库应该对其进行修复。
git clone https://github.com/koel/koel.git --recursive
如果不起作用,请尝试以下操作:
git submodule update --init --recursive