Skip to content

Commit 36e2d99

Browse files
authored
Add workflow to verify required documentation scripts
1 parent 2d48844 commit 36e2d99

1 file changed

Lines changed: 31 additions & 0 deletions

File tree

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Check scripts from docs
2+
3+
on:
4+
push:
5+
6+
jobs:
7+
verify-scripts:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- name: Checkout code
11+
uses: actions/checkout@v4
12+
13+
- name: "Verify all scripts linked in https://betterstack.com/docs/logs/collector exist"
14+
run: |
15+
missing=0
16+
17+
for file in install.sh uninstall.sh deploy-to-swarm.sh; do
18+
if [ ! -f "$file" ]; then
19+
echo "::error file=$file::Required file '$file' is missing."
20+
missing=1
21+
else
22+
echo "Found $file"
23+
fi
24+
done
25+
26+
if [ $missing -ne 0 ]; then
27+
echo "Some required files are missing."
28+
exit 1
29+
fi
30+
31+
echo "All required files are present."

0 commit comments

Comments
 (0)