-
Notifications
You must be signed in to change notification settings - Fork 35
/
.gitlab-ci.yml
44 lines (41 loc) · 1.48 KB
/
.gitlab-ci.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
image: michaelmcandrew/civicrm-buildkit:php8.0
variables:
CIVICRM_EXT_KEY:
value: ""
description: "The extension key (in long-form, if it uses the old style, ex: org.example.myext)"
CIVICRM_EXT_TAG:
value: ""
description: "Release tag to process"
before_script:
- apt -qq update && apt -qq install -y moreutils gettext
- curl -o- https://raw.githubusercontent.com/transifex/cli/master/install.sh | bash
- source ~/.bashrc
- git config --global user.email "[email protected]"
- git config --global user.name "CiviCRM Gitlab CICD"
update_transifex_extension:
stage: build
cache:
- key:
paths:
- civicrm-l10n-extensions/
script:
- php -v
- tx --version
- civistrings --version
- git clone https://mlutfy-civicrm:${GITHUB_TOKEN}@github.com/civicrm/civicrm-l10n-extensions.git || true
- cd civicrm-l10n-extensions
# This is just a precaution if the repo is cached and the token changed
- git remote rm origin
- git remote add origin https://mlutfy-civicrm:${GITHUB_TOKEN}@github.com/civicrm/civicrm-l10n-extensions.git
- git checkout -- .
- git pull origin master
- php ../bin/civiextensions-update-transifex.php --extkey="${CIVICRM_EXT_KEY}" --exttag="${CIVICRM_EXT_TAG}"
- git status
- git diff
- git add po
- git commit -m "Automatic commit (key=${CIVICRM_EXT_KEY:-all}, tag=${CIVICRM_EXT_TAG:-all})"
- git remote -v
- git push origin master
when: manual
tags:
- test-1-docker