zoukankan      html  css  js  c++  java
  • Scala + Activator + Sbt 搭建Play framework框架

    1.下载Typesafe Activator ,我下载的是1.3.7, 地址:typesafe 官网

    2.  配置Path: activator(E:developactivator-1.3.7)和sbt(E:developsbtin)

    3.使用typesafe 创建应用。2种方式:

      (1)CMD:    activator new my-first-app  play-java 

      (2)activator ui  

    4.  新建repository配置文件(任意位置)

    我的位置 E:developsbtconf epository.properties
    内容 [repositories]
    local
    activator: file:///E:/develop/activator-1.3.7/repository/, [organization]/[module]/(scala_[scalaVersion]/)(sbt_[sbtVersion]/)[revision]/[type]s/[artifact](-[classifier]).[ext]
    osc: http://maven.oschina.net/content/groups/public/
    typesafe: http://dl.bintray.com/typesafe/maven-releases/, [organization]/[module]/(scala_[scalaVersion]/)(sbt_[sbtVersion]/)[revision]/[type]s/[artifact](-[classifier]).[ext], bootOnly
    ivy-releases: http://dl.bintray.com/typesafe/ivy-releases/, [organization]/[module]/(scala_[scalaVersion]/)(sbt_[sbtVersion]/)[revision]/[type]s/[artifact](-[classifier]).[ext]
    sbt-plugin: http://dl.bintray.com/sbt/sbt-plugin-releases/
    sonatype-oss-releases
    maven-central
    sonatype-oss-snapshots

    5.(1)修改E:developactivator-1.3.7activator-launch-1.3.7.jar 

    7Zip -> sbt -> 修改sbt.boot.properties
    [repositories]
    local
    activator-launcher-local: file:///E:/develop/activator-1.3.7/repository/, [organization]/[module]/(scala_[scalaVersion]/)(sbt_[sbtVersion]/)[revision]/[type]s/[artifact](-[classifier]).[ext]
    maven-central
    typesafe-releases: http://dl.bintray.com/typesafe/maven-releases/
    typesafe-ivy-releasez: http://dl.bintray.com/typesafe/ivy-releases/, [organization]/[module]/(scala_[scalaVersion]/)(sbt_[sbtVersion]/)[revision]/[type]s/[artifact](-[classifier]).[ext]

    [boot]
    directory: E:developsbt.sbtoot
    properties: ${activator.boot.properties-${user.home}/.activator/version-${activator.launcher.generation-1}.properties}

    [ivy]
    ivy-home: E:developsbt.ivy2
    checksums: ${sbt.checksums-sha1,md5}
    override-build-repos: true
    repository-config: E:developsbtconf epository.properties

    6.addSbtPlugin("com.typesafe.play" % "sbt-plugin" % "2.4.4")   2.4.6->2.4.6  (原因:sbt-plugin.jar 2.4.6 下载不了)

    若是基于代理:在用户目录下 .activator下创建文件activatorconfig.txt

    # Proxy settings
    -Dhttp.proxyHost=116.228.220.198
    -Dhttp.proxyPort=2222
    -Dhttps.proxyHost=116.228.220.198
    -Dhttps.proxyPort=2222
    # Here we configure the hosts which should not go through the proxy. You should include your private network, if applicable.
    -Dhttp.nonProxyHosts="localhost|127.0.0.1"
    -Dhttps.nonProxyHosts="localhost|127.0.0.1"
    # These are commented out, but if you need to use authentication for your proxy, please fill these out.
    -Dhttp.proxyUser=johnson.yang
    -Dhttps.proxyUser=johnson.yang123

    -Dhttps.proxyPassword=johnson.yang
    -Dhttp.proxyPassword=johnson.yang123

  • 相关阅读:
    electron 显示对话框 showMessageBoxSync showMessageBox
    c++ 随机数 取值范围 多线程
    c++ 字符串转换为数字
    VS2019 C++动态链接库的创建使用(1)
    js mutationobserver property vs attribute
    Chromium base 基础库概览
    Git:合并分支----git merge命令应用的三种情景
    chromium 处理 addEventListener 事件
    JavaScript监听属性改变
    chrome 启动开关参数
  • 原文地址:https://www.cnblogs.com/fight-tao/p/5001394.html
Copyright © 2011-2022 走看看