wedroid/.drone.yml

111 lines
2.2 KiB
YAML
Raw Permalink Normal View History

2019-11-07 18:29:47 +00:00
kind: pipeline
type: docker
name: default
steps:
- name: build
2019-11-24 20:39:13 +00:00
image: nextcloudci/android:android-49
volumes:
- name: gradle
path: /root/.gradle
- name: android
path: /opt/android-sdk-linux
2019-11-07 18:29:47 +00:00
commands:
2019-11-24 20:39:13 +00:00
- ./gradlew build
2019-11-07 18:29:47 +00:00
- name: notify
image: appleboy/drone-telegram
settings:
token:
from_secret: telegram_token
to:
from_secret: telegram_user
format: markdown
message: |
Build [#{{build.number}}]({{build.link}}) from commit [{{truncate commit.sha 10}}]({{commit.link}}) on {{commit.branch}} **failed**.
2019-11-07 18:29:47 +00:00
{{uppercasefirst commit.author}} please fix me!
when:
status:
- failure
volumes:
- name: gradle
host:
2019-11-28 14:02:26 +00:00
path: /home/drone/.gradle
- name: android
host:
2019-11-28 14:02:26 +00:00
path: /home/drone/Android/Sdk
2020-01-08 19:44:22 +00:00
trigger:
2020-01-12 16:30:06 +00:00
event:
2020-01-08 19:44:22 +00:00
exclude:
2020-01-12 16:30:06 +00:00
- tag
2020-01-08 19:44:22 +00:00
---
kind: pipeline
type: docker
2020-01-12 16:30:06 +00:00
name: release
2020-01-08 19:44:22 +00:00
steps:
- name: build
image: nextcloudci/android:android-49
2020-01-12 16:30:06 +00:00
volumes:
2020-01-12 20:05:51 +00:00
- name: gradle
path: /root/.gradle
- name: android
path: /opt/android-sdk-linux
2020-01-12 16:30:06 +00:00
- name: tmp
path: /drone/src/out
2020-01-08 19:44:22 +00:00
commands:
2020-01-12 17:04:55 +00:00
- ./gradlew build
2020-01-12 18:55:45 +00:00
- ./gradlew :wrapper:fatJar
2020-01-12 16:30:06 +00:00
- mv /drone/src/wrapper/build/libs/*.jar /drone/src/out/
2020-01-12 17:14:44 +00:00
- mv /drone/src/app/build/outputs/apk/release/*.apk /drone/src/out/
2020-01-12 16:30:06 +00:00
- name: gitea release
image: plugins/gitea-release
volumes:
- name: tmp
path: /drone/src/out
settings:
api_key:
from_secret: gitea_release
base_url: https://git.norangeb.it
title: wedroid
files:
- /drone/src/out/*.jar
- /drone/src/out/*.apk
checksum:
- md5
- sha256
2020-01-08 19:44:22 +00:00
- name: notify
image: appleboy/drone-telegram
settings:
token:
from_secret: telegram_token
to:
from_secret: telegram_user
format: markdown
message: |
2020-01-12 20:05:51 +00:00
{{#success build.status}}
Release-{{build.tag}} successfully released.
{{else}}
Build [#{{build.number}}]({{build.link}}) from commit [{{truncate commit.sha 10}}]({{commit.link}}) with tag {{build.tag}} **failed**.
{{uppercasefirst commit.author}} please fix me!
{{/success}}
2020-01-08 19:44:22 +00:00
2020-01-12 16:30:06 +00:00
volumes:
- name: tmp
temp: {}
2020-01-12 20:05:51 +00:00
- name: gradle
host:
path: /home/drone/.gradle
- name: android
host:
path: /home/drone/Android/Sdk
2020-01-12 16:30:06 +00:00
2020-01-08 19:44:22 +00:00
trigger:
2020-01-12 16:30:06 +00:00
event:
- tag