Skip to content

Commit 56cd972

Browse files
thst-nordicmbolivar-nordic
authored andcommitted
[nrf noup] ci: add downstream-only NCS customizations
Add Jenkinsfile, .gitlint, and backport workflow files. Signed-off-by: Thomas Stilwell <Thomas.Stilwell@nordicsemi.no> Signed-off-by: Ulrich Myhre <ulrich.solli.myhre@nordicsemi.no> Signed-off-by: Chris Bittner <chris.bittner@nordicsemi.no> Signed-off-by: Martí Bolívar <marti.bolivar@nordicsemi.no> Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no> Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no> (cherry picked from commit 624bd7c)
1 parent e86f575 commit 56cd972

File tree

3 files changed

+82
-0
lines changed

3 files changed

+82
-0
lines changed

.github/workflows/backport.yml

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
name: Backport
2+
on:
3+
pull_request:
4+
types:
5+
- closed
6+
- labeled
7+
8+
jobs:
9+
backport:
10+
runs-on: ubuntu-18.04
11+
name: Backport
12+
steps:
13+
- name: Backport Bot
14+
uses: Gaurav0/backport@v1.0.24
15+
with:
16+
bot_username: NordicBuilder
17+
bot_token: 151a9b45052f9ee8be5a59963d31ad7b92c3ecb5
18+
bot_token_key: 67bb1f1f998d546859786a4088917c65415c0ebd
19+
github_token: ${{ secrets.GITHUB_TOKEN }}

.gitlint

+57
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
# All these sections are optional, edit this file as you like.
2+
[general]
3+
ignore=title-trailing-punctuation, T3, title-max-length, T1, body-hard-tab, B3, B1
4+
# verbosity should be a value between 1 and 3, the commandline -v flags take precedence over this
5+
verbosity = 3
6+
# By default gitlint will ignore merge commits. Set to 'false' to disable.
7+
ignore-merge-commits=true
8+
# Enable debug mode (prints more output). Disabled by default
9+
debug = false
10+
11+
# Set the extra-path where gitlint will search for user defined rules
12+
# See http://jorisroovers.github.io/gitlint/user_defined_rules for details
13+
extra-path=../../zephyr/scripts/gitlint
14+
15+
[title-max-length-no-revert]
16+
line-length=72
17+
18+
[body-min-line-count]
19+
min-line-count=1
20+
21+
[body-max-line-count]
22+
max-line-count=200
23+
24+
[title-starts-with-subsystem]
25+
regex = ^(?!subsys:)(([^:]+):)(\s([^:]+):)*\s(.+)$
26+
27+
[title-must-not-contain-word]
28+
# Comma-separated list of words that should not occur in the title. Matching is case
29+
# insensitive. It's fine if the keyword occurs as part of a larger word (so "WIPING"
30+
# will not cause a violation, but "WIP: my title" will.
31+
words=wip
32+
33+
[title-match-regex]
34+
# python like regex (https://docs.python.org/2/library/re.html) that the
35+
# commit-msg title must be matched to.
36+
# Note that the regex can contradict with other rules if not used correctly
37+
# (e.g. title-must-not-contain-word).
38+
#regex=^US[0-9]*
39+
40+
[max-line-length-with-exceptions]
41+
# B1 = body-max-line-length
42+
line-length=72
43+
44+
[body-min-length]
45+
min-length=3
46+
47+
[body-is-missing]
48+
# Whether to ignore this rule on merge commits (which typically only have a title)
49+
# default = True
50+
ignore-merge-commits=false
51+
52+
[body-changed-file-mention]
53+
# List of files that need to be explicitly mentioned in the body when they are changed
54+
# This is useful for when developers often erroneously edit certain files or git submodules.
55+
# By specifying this rule, developers can only change the file when they explicitly reference
56+
# it in the commit message.
57+
#files=gitlint/rules.py,README.md

Jenkinsfile

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
@Library("CI_LIB") _
2+
3+
def pipeline = new ncs.sdk_mcuboot.Main()
4+
5+
pipeline.run(JOB_NAME)
6+

0 commit comments

Comments
 (0)