mirror of
https://github.com/xHyroM/zed-discord-presence.git
synced 2024-11-22 14:11:04 +01:00
ci: actually release
This commit is contained in:
parent
eb3ed250fc
commit
b0679dc83a
1 changed files with 33 additions and 3 deletions
36
.github/workflows/release.yml
vendored
36
.github/workflows/release.yml
vendored
|
@ -1,6 +1,10 @@
|
||||||
name: Release
|
name: Release
|
||||||
on:
|
on:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
inputs:
|
||||||
|
version:
|
||||||
|
description: "lsp version"
|
||||||
|
required: true
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
check:
|
check:
|
||||||
|
@ -70,15 +74,18 @@ jobs:
|
||||||
|
|
||||||
if [[ "${{ matrix.archive }}" == "tar.gz" ]]; then
|
if [[ "${{ matrix.archive }}" == "tar.gz" ]]; then
|
||||||
ARCHIVE_PATH="tmp/${ARCHIVE_NAME}.tar.gz"
|
ARCHIVE_PATH="tmp/${ARCHIVE_NAME}.tar.gz"
|
||||||
tar -czvf "${ARCHIVE_PATH}" -C "tmp/${ARCHIVE_NAME}" .
|
tar -czvf "${ARCHIVE_PATH}" -C "tmp" "${ARCHIVE_NAME}"
|
||||||
else
|
else
|
||||||
ARCHIVE_PATH="tmp/${ARCHIVE_NAME}.zip"
|
ARCHIVE_PATH="tmp/${ARCHIVE_NAME}.zip"
|
||||||
|
|
||||||
|
cd tmp
|
||||||
if [[ "${{ matrix.runner }}" == "windows-latest" ]]; then
|
if [[ "${{ matrix.runner }}" == "windows-latest" ]]; then
|
||||||
7z a "${ARCHIVE_PATH}" "tmp/${ARCHIVE_NAME}"
|
7z a "../${ARCHIVE_PATH}" "${ARCHIVE_NAME}"
|
||||||
else
|
else
|
||||||
zip -r "${ARCHIVE_PATH}" "tmp/${ARCHIVE_NAME}"
|
zip -r "../${ARCHIVE_PATH}" "/${ARCHIVE_NAME}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
cd ..
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "archive_name=${ARCHIVE_NAME}" >> $GITHUB_OUTPUT
|
echo "archive_name=${ARCHIVE_NAME}" >> $GITHUB_OUTPUT
|
||||||
|
@ -90,3 +97,26 @@ jobs:
|
||||||
name: ${{ steps.vars.outputs.archive_name }}
|
name: ${{ steps.vars.outputs.archive_name }}
|
||||||
path: |
|
path: |
|
||||||
${{ steps.vars.outputs.archive_path }}
|
${{ steps.vars.outputs.archive_path }}
|
||||||
|
|
||||||
|
release:
|
||||||
|
name: release
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: checkout
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: download artifacts
|
||||||
|
uses: actions/download-artifact@v3
|
||||||
|
with:
|
||||||
|
path: artifacts
|
||||||
|
|
||||||
|
- name: Create the release
|
||||||
|
uses: softprops/action-gh-release@c062e08bd532815e2082a85e87e3ef29c3e6d191
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
with:
|
||||||
|
tag_name: v${{ inputs.version }}
|
||||||
|
name: v${{ inputs.version }}
|
||||||
|
draft: true
|
||||||
|
files: |
|
||||||
|
artifacts/*
|
||||||
|
|
Loading…
Reference in a new issue