-
Notifications
You must be signed in to change notification settings - Fork 0
47 lines (40 loc) · 1.21 KB
/
main.yml
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
name: Run Main Script
on:
workflow_dispatch:
inputs:
page_url:
description: 'Page URL to loop pages'
required: true
base_url:
description: 'Base URL'
required: true
entity_identifier:
description: 'Entity html tag'
required: true
file_name:
description: 'File Name'
required: true
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v2
- name: Set up Ruby
uses: actions/setup-ruby@v1
with:
ruby-version: '3.1'
bundler-cache: true
- run: bundle exec rake
- name: Install Dependencies
run: |
gem install nokogiri linkeddata
- name: Run Main Script
run: ruby main.rb ${{ github.event.inputs.page_url }} ${{ github.event.inputs.base_url }} ${{ github.event.inputs.entity_identifier }} ${{ github.event.inputs.file_name }}
- name: Commit and Push Changes
run: |
git config --local user.email "[email protected]"
git config --local user.name "GitHub Actions"
git add ${{ github.event.inputs.file_name }}
git commit -m "Add data generated by the script"
git push