错误安装sbt

问题描述 投票:0回答:1

我试着在High Sierra上安装SBT。

我已经用 "brew install sbt "安装了构建工具,之后我试着在".brewCellarsbt1.1.0binsbt "上运行sbt。

我得到了这个错误。

java.io.IOException: Operation not supported
at sun.nio.ch.FileDispatcherImpl.lock0(Native Method)
at sun.nio.ch.FileDispatcherImpl.lock(FileDispatcherImpl.java:90)
at sun.nio.ch.FileChannelImpl.tryLock(FileChannelImpl.java:1115)
at java.nio.channels.FileChannel.tryLock(FileChannel.java:1155)
at xsbt.boot.Locks$GlobalLock.withChannel$1(Locks.scala:88)
at xsbt.boot.Locks$GlobalLock.xsbt$boot$Locks$GlobalLock$$withChannelRetries$1(Locks.scala:80)
at xsbt.boot.Locks$GlobalLock$$anonfun$withFileLock$1.apply(Locks.scala:99)
at xsbt.boot.Using$.withResource(Using.scala:10)
at xsbt.boot.Using$.apply(Using.scala:9)
at xsbt.boot.Locks$GlobalLock.ignoringDeadlockAvoided(Locks.scala:60)
at xsbt.boot.Locks$GlobalLock.withLock(Locks.scala:50)
at xsbt.boot.Locks$.apply0(Locks.scala:31)
at xsbt.boot.Locks$.apply(Locks.scala:28)
at xsbt.boot.Launch.locked(Launch.scala:238)
at xsbt.boot.Launch.app(Launch.scala:147)
at xsbt.boot.Launch.app(Launch.scala:145)
at xsbt.boot.Launch$.run(Launch.scala:102)
at xsbt.boot.Launch$$anonfun$apply$1.apply(Launch.scala:35)
at xsbt.boot.Launch$.launch(Launch.scala:117)
at xsbt.boot.Launch$.apply(Launch.scala:18)
at xsbt.boot.Boot$.runImpl(Boot.scala:41)
at xsbt.boot.Boot$.main(Boot.scala:17)
at xsbt.boot.Boot.main(Boot.scala)

Sbt执行过程中出错:java.io.IOException: 操作不支持

sbt
1个回答
0
投票

其实你不需要 自酿 来安装SBT。 直接在以下网站下载 https:/www.scala-sbt.orgdownload.html然后将其解压并放到你的主目录中。

使用终端,更新权限。

chmod -R 700 sbt/bin/sb

打开Bash配置文件

nano .bash_profile

在文件末尾添加以下一行。

export PATH=Usersusernamesbtbin:$PATH...

帳號 是您的用户名。 例如,导出PATH=Usersjohnsbtbin:$PATH。

要测试,关闭并重新打开终端。 运行。

sbt --version

我写了一步步的说明 我的博客 早些时候。

© www.soinside.com 2019 - 2024. All rights reserved.