Update create-discord-thread.yml
This commit is contained in:
parent
4cc5a69986
commit
e00542a62f
16
.github/workflows/create-discord-thread.yml
vendored
16
.github/workflows/create-discord-thread.yml
vendored
@ -55,7 +55,7 @@ jobs:
|
|||||||
JSON=$(wget -qLO - https://github.com/community-scripts/ProxmoxVED/raw/main/json/${{ env.TITLE }}.json)
|
JSON=$(wget -qLO - https://github.com/community-scripts/ProxmoxVED/raw/main/json/${{ env.TITLE }}.json)
|
||||||
username=$(echo "$JSON" | jq -r '.default_credentials.username')
|
username=$(echo "$JSON" | jq -r '.default_credentials.username')
|
||||||
password=$(echo "$JSON" | jq -r '.default_credentials.password')
|
password=$(echo "$JSON" | jq -r '.default_credentials.password')
|
||||||
notes=($(echo "$JSON" | jq -r '.notes[].text'))
|
mapfile -t notes_array < <(echo "$JSON" | jq -r '.notes[].text')
|
||||||
|
|
||||||
if [[ -n "$username" && "$username" != "null" || -n "$password" && "$password" != "null" ]]; then
|
if [[ -n "$username" && "$username" != "null" || -n "$password" && "$password" != "null" ]]; then
|
||||||
VAR+="Default credentials:\n"
|
VAR+="Default credentials:\n"
|
||||||
@ -70,14 +70,12 @@ jobs:
|
|||||||
VAR+="\n"
|
VAR+="\n"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ${#notes[@]} -gt 0 ]; then
|
if [ ${#notes_array[@]} -gt 0 ]; then
|
||||||
VAR+="Notes:\n"
|
for note in "${notes_array[@]}"; do
|
||||||
for note in "${notes[@]}"; do
|
VAR+="$note\n"
|
||||||
VAR+="$note"
|
done
|
||||||
done
|
VAR+="\n"
|
||||||
VAR+="\n"
|
fi
|
||||||
fi
|
|
||||||
|
|
||||||
fi
|
fi
|
||||||
VAR+="Note: This is not in the official repo yet—it's just a dev version! After merging into ProxmoxVE, it will need to be recreated.\n\n"
|
VAR+="Note: This is not in the official repo yet—it's just a dev version! After merging into ProxmoxVE, it will need to be recreated.\n\n"
|
||||||
VAR+="Discussion & issue tracking:\n"
|
VAR+="Discussion & issue tracking:\n"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user