We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a2e37dd commit e23990bCopy full SHA for e23990b
.forgejo/workflows/tofu-issue-deploy.yml
@@ -18,8 +18,18 @@ jobs:
18
ISSUE_BODY="${{ github.event.issue.body }}"
19
echo "ISSUE_BODY=$ISSUE_BODY"
20
21
+ # Check if 'VM Name' is in the body
22
+ echo "$ISSUE_BODY" | grep 'VM Name' # This should print the line with 'VM Name'
23
+
24
+ # Extract the value for VM_NAME
25
VM_NAME=$(echo "$ISSUE_BODY" | grep -A 1 'VM Name' | tail -n 1 | xargs)
- echo "VM_NAME=$VM_NAME"
26
+ echo "Extracted VM_NAME: '$VM_NAME'" # Debugging extracted value
27
28
+ if [ -z "$VM_NAME" ]; then
29
+ echo "Error: VM_NAME is empty. Check the formatting of the input."
30
+ else
31
+ echo "VM_NAME=$VM_NAME" # Display the value if extracted correctly
32
+ fi
33
34
VM_ID=$(echo "$ISSUE_BODY" | grep 'VM ID:' | cut -d':' -f2 | xargs)
35
RAM=$(echo "$ISSUE_BODY" | grep 'RAM:' | cut -d':' -f2 | xargs)
0 commit comments