简体   繁体   English

如何在 Mac 上安装 spring boot CLI?

[英]How to install spring boot CLI on Mac?

I am trying to install the Spring Boot CLI.我正在尝试安装 Spring Boot CLI。 I followed the instructions from the website.我按照网站上的说明进行操作。 ( https://docs.spring.io/spring-boot/docs/current/reference/html/getting-started-installing-spring-boot.html ) The error I am getting is: https://docs.spring.io/spring-boot/docs/current/reference/html/getting-started-installing-spring-boot.html )我得到的错误是:

$ spring --version rbenv: spring: command not found $ spring --version rbenv: spring: 命令未找到

The `spring' command exists in these Ruby versions: 2.4.0 “spring”命令存在于以下 Ruby 版本中:2.4.0

I ran all the brew and bundle installs, but I am still running into issues.我运行了所有的 brew 和 bundle 安装,但我仍然遇到问题。 Any suggestions?有什么建议么?

Better using Homebrew更好地使用Homebrew

  1. Install Homebrew using /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"使用/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"安装 Homebrew

  2. Check if Homebrew installed using brew -v使用brew -v检查 Homebrew 是否安装

  3. Update Homebrew packager brew tap pivotal/tap更新 Homebrew 打包程序brew tap pivotal/tap

  4. Install Spring Boot CLI using brew install springboot使用brew install springboot安装 Spring Boot CLI

Homebrew installs spring to /usr/local/bin Homebrew 将 spring 安装到 /usr/local/bin

  1. Check Spring Boot CLI using spring version使用spring version检查 Spring Boot CLI

If you want to remove it use brew uninstall springboot , add additional --force to force it如果你想删除它使用brew uninstall springboot ,添加额外的--force来强制它

Windows users:视窗用户:

Download the zip下载压缩包

https://repo.spring.io/release/org/springframework/boot/spring-boot-cli/2.0.2.RELEASE/spring-boot-cli-2.0.2.RELEASE-bin.zip

Extract & Run spring.bat inside the /bin folder在 /bin 文件夹中提取并运行 spring.bat

Mac users: Mac 用户:

$> brew tap pivotal/tap

$> brew install springboot

Spring Boot has relocated to spring-io/tap Spring Boot 已迁移至 spring-io/tap

brew tap spring-io/tap
brew uninstall springboot
brew install spring-boot

您可以使用 sdkman http://sdkman.io/我无法提交如此简短的答案,因此添加了更多文本...

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM