-
Notifications
You must be signed in to change notification settings - Fork 1
58 lines (48 loc) · 1.4 KB
/
open-drive.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
48
49
50
51
52
53
54
55
56
57
58
name: Ouverture du Drive
on:
schedule:
- cron: '0 0 * * *'
push:
branches:
- master
repository_dispatch:
types: [open]
env:
TZ: Europe/Paris
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [12.x]
steps:
- uses: actions/checkout@v2
with:
ref: ${{ github.head_ref }}
token: ${{ secrets.GITHUB_TOKEN }}
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: npm install
run: |
npm install
env:
CI: true
- name: open drive
run: |
npm run open_drive
cp -r public/images .
env:
ALGOLIA_SECRET_KEY: ${{ secrets.ALGOLIA_SECRET_KEY }}
ODOO_USER: ${{ secrets.ODOO_USER }}
ODOO_PASSWORD: ${{ secrets.ODOO_PASSWORD }}
- name: Get Current Date
run: echo "CURRENT_DATE=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
- uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: "Mise à jour des produits au jour ${{ env.CURRENT_DATE }}"
token: ${{ secrets.GITHUB_TOKEN }}
author_name: github-actions[bot]
author_email: github-actions[bot]@users.noreply.github.com
commit_author: Author <[email protected]>