【问题标题】:How to install sbt on ubuntu/debian with apt-get [closed]如何使用 apt-get 在 ubuntu/debian 上安装 sbt [关闭]
【发布时间】:2016-06-02 11:29:24
【问题描述】:

sbt 安装说明表明sbt 在存储库中。然而:

$ sudo apt-get install -y sbt
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Unable to locate package sbt

让我们看看周围..

$ s apt-cache search sbt
coop-computing-tools - cooperative computing tools
libnet-z3950-simpleserver-perl - simple perl API for building Z39.50 servers
libusbtc08-1 - Hardware interface library for PicoTech USB TC08 Thermocouple sensor
libusbtc08-dev - Development files for PicoTech USB TC08
python-usbtc08 - Python wrapper for libusbtc08
s51dude - In-System Programmer for 8051 MCUs using usbtiny

嗯.. 没有..

那么 apt-get 是否可以在 ubuntu 上使用 sbt?有专门的apt repository吗?

【问题讨论】:

    标签: ubuntu sbt


    【解决方案1】:

    经过更多搜索,在这里找到了答案:http://www.scala-sbt.org/0.13/docs/Installing-sbt-on-Linux.html

    echo "deb https://dl.bintray.com/sbt/debian /" | sudo tee -a /etc/apt/sources.list.d/sbt.list
    sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 642AC823
    sudo apt-get update
    sudo apt-get install sbt
    

    这个确实有效

    sbt
      Getting org.scala-sbt sbt 0.13.9 ...
    

    然后..耐心点..

    【讨论】:

    • 我做了所有这些,但最后,当我说aptitude install sbt 时,我收到警告:不受信任的软件包可能会危及您系统的安全性。如果您确定这是您想要做的,您应该只继续安装。 sbt dl.bintray.com/sbt/debian/sbt-0.13.13.deb 你想忽略这个警告并继续吗?要继续,请输入“是”;要中止,请输入“否”:
    • sudo apt-get install sbt Reading package lists... Done Building dependency tree Reading state information... Done E: Unable to locate package sbt
    【解决方案2】:

    或者,您也可以通过以下方式安装它:

    export SBT_VERSION=1.5.5
    curl -L -o sbt-$SBT_VERSION.zip https://github.com/sbt/sbt/releases/download/v$SBT_VERSION/sbt-$SBT_VERSION.zip
    unzip sbt-$SBT_VERSION.zip -d ops
    

    请将上面的1.5.5 替换为您想要的sbt 的实际版本。

    参考:

    【讨论】:

    • sbt.dev 不是 Debian 格式档案。
    • 对我不起作用
    • @6005 感谢您的评论,我更新了链接。你介意再试一次吗?
    猜你喜欢
    • 2012-03-04
    • 2018-11-13
    • 1970-01-01
    • 2013-03-10
    • 1970-01-01
    • 2014-10-17
    • 1970-01-01
    • 2014-06-19
    • 1970-01-01
    相关资源
    最近更新 更多