Skip to content

Commit 51700a0

Browse files
committed
softprops/[email protected] tag_name: v1.0
1 parent b0101c5 commit 51700a0

File tree

1 file changed

+43
-28
lines changed

1 file changed

+43
-28
lines changed

.github/workflows/docker-build.yaml

+43-28
Original file line numberDiff line numberDiff line change
@@ -29,40 +29,45 @@ jobs:
2929
# IMAGE_REGISTRY='quay.io'
3030
# echo '${{ secrets.REDHAT_QUAY_PASSWORD }}' | docker login --username '${{ secrets.REDHAT_QUAY_USERNAME }}' --password-stdin "$IMAGE_REGISTRY"
3131
# docker buildx build --push --platform 'linux/amd64' --tag "$IMAGE_REGISTRY/${{ github.repository }}:$IMAGE_TAG" --file Dockerfile .
32+
# ###############################################
3233
# https://github.com/typst-doc-cn/tutorial/commit/8cc1d86152139e248b4107e7c649ea63dfabeab7#diff-5c3fa597431eda03ac3339ae6bf7f05e1a50d6fc7333679ec38e21b337cb6721R15
3334
# Artifact ebook.zip successfully finalized. Artifact ID 2259179758
3435
# Artifact ebook has been successfully uploaded! Final size is 138 bytes. Artifact ID is 2259179758
3536
# Artifact download URL: https://github.com/infrastlabs/build-nginx/actions/runs/12111045794/artifacts/2259179758
36-
# - uses: actions/upload-artifact@v4
37+
# ###############################################
38+
# - uses: actions/upload-artifact@v4 #直接upload, OK
3739
# id: artifact-upload-step
3840
# with:
3941
# name: ebook
4042
# path: ebook.pdf
4143
# - run: echo 'Artifact URL is ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}/artifacts/${{ steps.artifact-upload-step.outputs.artifact-id }}'
4244
#
45+
# ###############################################
4346
# https://blog.csdn.net/m0_57236802/article/details/133850667
4447
# Parameter token or opts.auth is required
4548
# Published releases must have a valid tag: pre_receive Sorry, branch or tag names starting with 'refs/' are not allowed.
46-
- name: Create Release
47-
id: create_release
48-
uses: actions/create-release@v1
49-
# https://blog.csdn.net/gitblog_00919/article/details/142539600
50-
env:
51-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} #官方内置的 secrets ,我们直接使用就可
52-
with:
53-
tag_name: v1.0 #${{ github.ref }}
54-
release_name: Release v1.0 #${{ github.ref }}
55-
body: |
56-
Automated release for tag ${{ github.ref }}
57-
draft: false
58-
prerelease: false
59-
- name: Upload File
60-
uses: actions/upload-release-asset@v1
61-
with:
62-
upload_url: ${{ steps.create_release.outputs.upload_url }}
63-
asset_path: ebook.pdf
64-
asset_name: ebook
65-
asset_content_type: application/vnd.android.package-archive
49+
# Bad credentials; [email protected]
50+
# ###############################################
51+
# - name: Create Release
52+
# id: create_release
53+
# uses: actions/create-release@v1 #creds错误; [email protected]
54+
# env:
55+
# # https://blog.csdn.net/gitblog_00919/article/details/142539600
56+
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} #官方内置的 secrets ,我们直接使用就可
57+
# with:
58+
# tag_name: v1.0 #${{ github.ref }}
59+
# release_name: Release v1.0 #${{ github.ref }}
60+
# body: |
61+
# Automated release for tag ${{ github.ref }}
62+
# draft: false
63+
# prerelease: false
64+
# - name: Upload File
65+
# uses: actions/upload-release-asset@v1
66+
# with:
67+
# upload_url: ${{ steps.create_release.outputs.upload_url }}
68+
# asset_path: ebook.pdf
69+
# asset_name: ebook
70+
# asset_content_type: application/vnd.android.package-archive
6671
# 再次触发action的时候如何在同一个release下增加文件
6772
# - name: Get Release
6873
# id: get_release
@@ -79,12 +84,22 @@ jobs:
7984
# asset_name: app-release.apk
8085
# asset_content_type: application/vnd.android.package-archive
8186
#
87+
# ###############################################
8288
# https://blog.csdn.net/heroboyluck/article/details/142185264
8389
# GitHub Releases requires a tag
84-
# - name: create github release
85-
# id: new_release
86-
# uses: softprops/[email protected]
87-
# with:
88-
# name: latest
89-
# make_latest: true
90-
# files: ebook.pdf
90+
# https://github.com/softprops/action-gh-release
91+
# outputs
92+
# ###############################################
93+
- name: create github release
94+
id: new_release
95+
uses: softprops/[email protected]
96+
# if: startsWith(github.ref, 'refs/tags/')
97+
with:
98+
name: latest
99+
tag_name: v1.0
100+
make_latest: true
101+
# files: ebook.pdf
102+
files: |
103+
ebook.pdf
104+
LICENSE
105+

0 commit comments

Comments
 (0)