-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathrelease.sh
More file actions
30 lines (23 loc) · 1010 Bytes
/
Copy pathrelease.sh
File metadata and controls
30 lines (23 loc) · 1010 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
###
# @Author: Vincent Yang
# @Date: 2025-04-04 17:41:22
# @LastEditors: Vincent Yang
# @LastEditTime: 2025-04-04 17:41:56
# @FilePath: /bob-plugin-raycast/release.sh
# @Telegram: https://t.me/missuo
# @GitHub: https://github.com/missuo
#
# Copyright © 2025 by Vincent, All Rights Reserved.
###
version=${1#refs/tags/v}
zip -r -j bob-plugin-raycast-$version.bobplugin src/*
sha256_raycast=$(sha256sum bob-plugin-raycast-$version.bobplugin | cut -d ' ' -f 1)
echo $sha256_raycast
download_link="https://github.com/missuo/bob-plugin-raycast/releases/download/v$version/bob-plugin-raycast-$version.bobplugin"
new_version="{\"version\": \"$version\", \"desc\": \"None\", \"sha256\": \"$sha256_raycast\", \"url\": \"$download_link\", \"minBobVersion\": \"1.8.0\"}"
json_file='appcast.json'
json_data=$(cat $json_file)
updated_json=$(echo $json_data | jq --argjson new_version "$new_version" '.versions = [$new_version] + .versions')
echo $updated_json > $json_file
mkdir dist
mv *.bobplugin dist