-
Notifications
You must be signed in to change notification settings - Fork 47
60 lines (53 loc) · 1.78 KB
/
update-dependencies.yml
File metadata and controls
60 lines (53 loc) · 1.78 KB
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
59
60
name: Update dependencies
on:
schedule:
# Run automatically at 7AM PST Tuesday
- cron: '0 14 * * 2'
workflow_dispatch:
jobs:
update-dependencies-and-test:
name: Update Dependencies & Test
runs-on: ubuntu-latest
timeout-minutes: 20
strategy:
max-parallel: 1
matrix:
java: [ 8, 11, 17 ]
steps:
- name: Checkout smtpapi-java
uses: actions/checkout@v2
- name: Set up Java
uses: actions/setup-java@v2
with:
distribution: 'temurin'
java-version: ${{ matrix.java }}
cache: 'maven'
- name: Updating semver dependencies
run: make update-deps
- run: mvn install -Dgpg.skip -Dmaven.javadoc.skip=true -B -V
- name: Add & Commit
if: matrix.java == '17'
uses: EndBug/add-and-commit@v8.0.2
env:
GITHUB_TOKEN: ${{ secrets.SG_JAVA_GITHUB_TOKEN }}
with:
add: 'pom.xml'
default_author: 'github_actions'
message: 'chore: update smtpapi-java dependencies'
notify-on-failure:
name: Slack notify on failure
if: failure()
needs: [ update-dependencies-and-test ]
runs-on: ubuntu-latest
steps:
- uses: rtCamp/action-slack-notify@v2
env:
SLACK_COLOR: failure
SLACK_ICON_EMOJI: ':github:'
SLACK_MESSAGE: ${{ format('Update dependencies *{0}*, {1}/{2}/actions/runs/{3}', needs.update-dependencies-and-test.result, github.server_url, github.repository, github.run_id) }}
SLACK_TITLE: Action Failure - ${{ github.repository }}
SLACK_USERNAME: GitHub Actions
SLACK_MSG_AUTHOR: twilio-dx
SLACK_FOOTER: Posted automatically using GitHub Actions
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
MSG_MINIMAL: true