Skip to content

Commit 1abf963

Browse files
committed
Issue #33 add trigger for AskPlantnet
1 parent c0eb836 commit 1abf963

File tree

7 files changed

+56
-13
lines changed

7 files changed

+56
-13
lines changed
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
# create bot action trigger
2+
name: BES_trigger_askplantnet_action
3+
on:
4+
# every day at 10h and 15h UTC
5+
schedule:
6+
- cron: "00 10 * * *"
7+
- cron: "00 15 * * *"
8+
# Allows you to run this workflow manually from the Actions tab
9+
workflow_dispatch:
10+
11+
jobs:
12+
build:
13+
runs-on: ubuntu-latest
14+
15+
environment: github_actions_bes
16+
steps:
17+
- name: trigger botEnSky AskPlantNet ACTION
18+
env:
19+
BES_ACTION_TOKEN: ${{ secrets.BES_ACTION_TOKEN }}
20+
BES_ACTION_URL: ${{ secrets.BES_ACTION_URL }}
21+
run: |
22+
curl -q -H "API-TOKEN: ${BES_ACTION_TOKEN}" -H "PLUGIN-NAME: AskPlantnet" "${BES_ACTION_URL}"
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
# create bot simulation trigger
2+
name: BES_trigger_askplantnet_simulation
3+
on:
4+
# every day at 09h57 and 14h55 UTC
5+
schedule:
6+
- cron: "55 09 * * *"
7+
- cron: "55 14 * * *"
8+
# Allows you to run this workflow manually from the Actions tab
9+
workflow_dispatch:
10+
11+
jobs:
12+
build:
13+
runs-on: ubuntu-latest
14+
15+
environment: github_actions_bes
16+
steps:
17+
- name: trigger botEnSky AskPlantNet simulation
18+
env:
19+
BES_SIMULATION_TOKEN: ${{ secrets.BES_SIMULATION_TOKEN }}
20+
BES_SIMULATION_URL: ${{ secrets.BES_SIMULATION_URL }}
21+
run: |
22+
curl -q -H "API-TOKEN: ${BES_SIMULATION_TOKEN}" -H "PLUGIN-NAME: AskPlantnet" "${BES_SIMULATION_URL}"
Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,22 @@
11
# create bot action trigger
2-
name: BES_trigger_action
2+
name: BES_trigger_plantnet_action
33
on:
4-
# every day at 15h30 UTC
4+
# every day at 15h30 and 17h30 UTC
55
schedule:
66
- cron: "30 15 * * *"
7+
- cron: "30 17 * * *"
78
# Allows you to run this workflow manually from the Actions tab
89
workflow_dispatch:
910

10-
1111
jobs:
1212
build:
1313
runs-on: ubuntu-latest
1414

1515
environment: github_actions_bes
1616
steps:
17-
- name: trigger botEnSky ACTION
17+
- name: trigger botEnSky PlantNet ACTION
1818
env:
1919
BES_ACTION_TOKEN: ${{ secrets.BES_ACTION_TOKEN }}
20-
BES_ACTION_PLUGIN: ${{ secrets.BES_ACTION_PLUGIN }}
2120
BES_ACTION_URL: ${{ secrets.BES_ACTION_URL }}
2221
run: |
23-
curl -q -H "API-TOKEN: ${BES_ACTION_TOKEN}" -H "PLUGIN-NAME: ${BES_ACTION_PLUGIN}" "${BES_ACTION_URL}"
22+
curl -q -H "API-TOKEN: ${BES_ACTION_TOKEN}" -H "PLUGIN-NAME: Plantnet" "${BES_ACTION_URL}"

.github/workflows/trigger_simulation.yml renamed to .github/workflows/trigger_plantnet_simulation.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# create bot simulation trigger
2-
name: BES_trigger_simulation
2+
name: BES_trigger_plantnet_simulation
33
on:
44
# every day at 15h15 and 15h20 UTC
55
schedule:
@@ -14,10 +14,9 @@ jobs:
1414

1515
environment: github_actions_bes
1616
steps:
17-
- name: trigger botEnSky simulation
17+
- name: trigger botEnSky PlantNet simulation
1818
env:
1919
BES_SIMULATION_TOKEN: ${{ secrets.BES_SIMULATION_TOKEN }}
20-
BES_SIMULATION_PLUGIN: ${{ secrets.BES_SIMULATION_PLUGIN }}
2120
BES_SIMULATION_URL: ${{ secrets.BES_SIMULATION_URL }}
2221
run: |
23-
curl -q -H "API-TOKEN: ${BES_SIMULATION_TOKEN}" -H "PLUGIN-NAME: ${BES_SIMULATION_PLUGIN}" "${BES_SIMULATION_URL}"
22+
curl -q -H "API-TOKEN: ${BES_SIMULATION_TOKEN}" -H "PLUGIN-NAME: Plantnet" "${BES_SIMULATION_URL}"

.github/workflows/trigger_unmute.yml renamed to .github/workflows/trigger_unmute_action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# create bot unmute trigger
2-
name: BES_trigger_unmute
2+
name: BES_trigger_unmute_action
33
on:
44
# every day at 23 55 UTC
55
schedule:

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
"tst": "echo windows %TST% test&& set NODE_ENV=test&& mocha --trace-warnings --timeout 180000 --unhandled-rejections=strict tests/all-root.test.js tests/%TST%.test.js",
1313
"test": "echo ci-test&& set NODE_ENV=test&&c8 mocha --exit --unhandled-rejections=strict tests/*.test.js --timeout 50000",
1414
"ci-test": "echo ci-test&& export NODE_ENV=test&&c8 mocha --unhandled-rejections=strict tests/*.test.js --timeout 50000",
15+
"wipAPN": "curl -v -H 'API-TOKEN: SIMULATE_WITH_LOCAL_DEV_ACCOUNT' -H 'PLUGIN-NAME: AskPlantnet' http://localhost:5000/api/hook",
1516
"wipPN": "curl -v -H 'API-TOKEN: SIMULATE_WITH_LOCAL_DEV_ACCOUNT' -H 'PLUGIN-NAME: Plantnet' http://localhost:5000/api/hook",
1617
"wipUM": "curl -v -H 'API-TOKEN: SIMULATE_WITH_LOCAL_DEV_ACCOUNT' -H 'PLUGIN-NAME: UnMute' http://localhost:5000/api/hook"
1718
},

src/www/views/partials/faq.ejs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@
77

88
<p><b>A quelle heure te réveilles-tu ?</b> : <br/><br/>
99
Pour le moment ce n'est pas encore trop figé. en dehors des tirs manuels,<br/>
10-
Pour le plugin <b>PlantNet</b> : je simule à ~ 17h15/17h25, et pratique à 17h30.<br/>
11-
Pour le plugin <b>AskPlantnet</b> (en phase de test): je pratique à 12h00 et 17h00.
10+
Pour le plugin <b>PlantNet</b> : je simule à ~ 17h15/17h25, et pratique à 17h30, 19h30 (FR).<br/>
11+
Pour le plugin <b>AskPlantnet</b> (en phase de test): je pratique à 12h00 et 17h00 (FR).
1212
</p>
1313

1414
</div>

0 commit comments

Comments
 (0)