【问题标题】:Using Go beta releases with GitHub Actions将 Go beta 版本与 GitHub Actions 一起使用
【发布时间】:2022-01-20 04:01:16
【问题描述】:

是否可以在 GitHub Actions 中使用 Go 语言的预览版?

目前有一个 1.18 测试版,我想开始在我的项目中使用一些新的更改。

【问题讨论】:

标签: go github-actions


【解决方案1】:

似乎还不能通过该操作获得它,但您始终可以手动安装它。

这是一个例子:

name: Golang

on:
  workflow_dispatch:

jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - name: Setup go
        uses: actions/setup-go@v2
        with:
          go-version: 1.17.5
      - name: Install beta version
        run: |
          go install golang.org/dl/go1.18beta1@latest
          go1.18beta1 download
          cp $(which go1.18beta1) $(which go)
          go version

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2019-12-24
    • 1970-01-01
    • 2022-09-23
    • 2020-02-03
    • 2020-06-02
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多