Skip to content

Commit 4dde72c

Browse files
authored
Update plugin-version-checker.yml
1 parent 89ab4bd commit 4dde72c

File tree

1 file changed

+29
-8
lines changed

1 file changed

+29
-8
lines changed

.github/workflows/plugin-version-checker.yml

Lines changed: 29 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,32 @@
1-
- name: Check Plugins
1+
name: Check Plugin Versions
2+
3+
on:
4+
push:
5+
branches:
6+
- main # Trigger when commits are pushed to the main branch
7+
workflow_dispatch: # Allows manual trigger if needed
8+
9+
jobs:
10+
check-plugins:
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
# Step 1: Checkout the repository
15+
- name: Checkout Code
16+
uses: actions/checkout@v3
17+
18+
# Step 2: Set up Node.js
19+
- name: Set up Node.js
20+
uses: actions/setup-node@v3
21+
with:
22+
node-version: '18'
23+
24+
# Step 3: Install Dependencies
25+
- name: Install Dependencies
26+
run: npm install axios
27+
28+
# Step 4: Check Plugin Versions
29+
- name: Check Plugins
230
id: check-plugins
331
run: |
432
node -e "
@@ -20,18 +48,11 @@
2048
process.exit(1);
2149
}
2250
23-
// Debug: Log the plugin section
24-
console.log('Plugin Section:', pluginSection);
25-
2651
// Extract GitHub URLs from the plugin section
2752
const pluginRegex = /https:\/\/github\.com\/([\w-]+)\/([\w-]+)/g;
2853
const matches = [...pluginSection.matchAll(pluginRegex)];
2954
const plugins = matches.map(match => ({ owner: match[1], repo: match[2] }));
3055
31-
// Debug: Log matches and plugins
32-
console.log('Matches Found:', matches);
33-
console.log('Parsed Plugins:', plugins);
34-
3556
if (plugins.length === 0) {
3657
console.error('Error: No valid plugins found in the README file.');
3758
process.exit(1);

0 commit comments

Comments
 (0)