Import upstream version 20.4.2+ds
Debian Janitor
1 year, 3 months ago
0 | name: Build and run tests | |
1 | on: [push, pull_request] | |
2 | env: | |
3 | app_id: pvr.vuplus | |
4 | ||
5 | jobs: | |
6 | build: | |
7 | runs-on: ${{ matrix.os }} | |
8 | strategy: | |
9 | fail-fast: false | |
10 | matrix: | |
11 | include: | |
12 | - name: "Debian package test" | |
13 | os: ubuntu-18.04 | |
14 | CC: gcc | |
15 | CXX: g++ | |
16 | DEBIAN_BUILD: true | |
17 | #- os: ubuntu-18.04 | |
18 | #CC: gcc | |
19 | #CXX: g++ | |
20 | #- os: ubuntu-18.04 | |
21 | #CC: clang | |
22 | #CXX: clang++ | |
23 | #- os: macos-10.15 | |
24 | steps: | |
25 | - name: Install needed ubuntu depends | |
26 | env: | |
27 | DEBIAN_BUILD: ${{ matrix.DEBIAN_BUILD }} | |
28 | run: | | |
29 | if [[ $DEBIAN_BUILD == true ]]; then sudo add-apt-repository -y ppa:team-xbmc/xbmc-nightly; fi | |
30 | if [[ $DEBIAN_BUILD == true ]]; then sudo apt-get update; fi | |
31 | if [[ $DEBIAN_BUILD == true ]]; then sudo apt-get install fakeroot; fi | |
32 | - name: Checkout Kodi repo | |
33 | uses: actions/checkout@v2 | |
34 | with: | |
35 | repository: xbmc/xbmc | |
36 | ref: master | |
37 | path: xbmc | |
38 | - name: Checkout pvr.vuplus repo | |
39 | uses: actions/checkout@v2 | |
40 | with: | |
41 | path: ${{ env.app_id }} | |
42 | - name: Configure | |
43 | env: | |
44 | CC: ${{ matrix.CC }} | |
45 | CXX: ${{ matrix.CXX }} | |
46 | DEBIAN_BUILD: ${{ matrix.DEBIAN_BUILD }} | |
47 | run: | | |
48 | if [[ $DEBIAN_BUILD != true ]]; then cd ${app_id} && mkdir -p build && cd build; fi | |
49 | if [[ $DEBIAN_BUILD != true ]]; then cmake -DADDONS_TO_BUILD=${app_id} -DADDON_SRC_PREFIX=${{ github.workspace }} -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=${{ github.workspace }}/xbmc/addons -DPACKAGE_ZIP=1 ${{ github.workspace }}/xbmc/cmake/addons; fi | |
50 | if [[ $DEBIAN_BUILD == true ]]; then wget https://raw.githubusercontent.com/xbmc/xbmc/master/xbmc/addons/kodi-dev-kit/tools/debian-addon-package-test.sh && chmod +x ./debian-addon-package-test.sh; fi | |
51 | if [[ $DEBIAN_BUILD == true ]]; then sudo apt-get build-dep ${{ github.workspace }}/${app_id}; fi | |
52 | - name: Build | |
53 | env: | |
54 | CC: ${{ matrix.CC }} | |
55 | CXX: ${{ matrix.CXX }} | |
56 | DEBIAN_BUILD: ${{ matrix.DEBIAN_BUILD }} | |
57 | run: | | |
58 | if [[ $DEBIAN_BUILD != true ]]; then cd ${app_id}/build; fi | |
59 | if [[ $DEBIAN_BUILD != true ]]; then make; fi | |
60 | if [[ $DEBIAN_BUILD == true ]]; then ./debian-addon-package-test.sh ${{ github.workspace }}/${app_id}; fi |
0 | name: Changelog and Release | |
1 | # Update the changelog and news(optionally), bump the version, and create a release | |
2 | # | |
3 | # The release is created on the given branch, release and tag name format will be <version>-<branch> and | |
4 | # the body of the release will be created from the changelog.txt or news element in the addon.xml.in | |
5 | # | |
6 | # options: | |
7 | # - version_type: 'minor' / 'micro' # whether to do a minor or micro version bump | |
8 | # - changelog_text: string to add to the changelog and news | |
9 | # - update_news: 'true' / 'false' # whether to update the news in the addon.xml.in | |
10 | # - add_date: 'true' / 'false' # Add date to version number in changelog and news. ie. v1.0.1 (2021-7-17) | |
11 | ||
12 | on: | |
13 | workflow_dispatch: | |
14 | inputs: | |
15 | version_type: | |
16 | description: 'Create a ''minor'' or ''micro'' release?' | |
17 | required: true | |
18 | default: 'minor' | |
19 | changelog_text: | |
20 | description: 'Input the changes you''d like to add to the changelogs. Your text should be encapsulated in "''s with line feeds represented by literal \n''s. ie. "This is the first change\nThis is the second change"' | |
21 | required: true | |
22 | default: '' | |
23 | update_news: | |
24 | description: 'Update news in addon.xml.in? [true|false]' | |
25 | required: true | |
26 | default: 'true' | |
27 | add_date: | |
28 | description: 'Add date to version number in changelog and news. ie. "v1.0.1 (2021-7-17)" [true|false]' | |
29 | required: true | |
30 | default: 'false' | |
31 | ||
32 | jobs: | |
33 | default: | |
34 | runs-on: ubuntu-latest | |
35 | name: Changelog and Release | |
36 | ||
37 | steps: | |
38 | ||
39 | # Checkout the current repository into a directory (repositories name) | |
40 | - name: Checkout Repository | |
41 | uses: actions/checkout@v2 | |
42 | with: | |
43 | fetch-depth: 0 | |
44 | path: ${{ github.event.repository.name }} | |
45 | ||
46 | # Checkout the required scripts from kodi-pvr/pvr-scripts into the 'scripts' directory | |
47 | - name: Checkout Scripts | |
48 | uses: actions/checkout@v2 | |
49 | with: | |
50 | fetch-depth: 0 | |
51 | repository: kodi-pvr/pvr-scripts | |
52 | path: scripts | |
53 | ||
54 | # Install all dependencies required by the following steps | |
55 | # - libxml2-utils, xmlstarlet: reading news and version from addon.xml.in | |
56 | - name: Install dependencies | |
57 | run: | | |
58 | sudo apt-get install libxml2-utils xmlstarlet | |
59 | ||
60 | # Setup python version 3.9 | |
61 | - name: Set up Python | |
62 | uses: actions/setup-python@v2 | |
63 | with: | |
64 | python-version: '3.9' | |
65 | ||
66 | # Run the python script to increment the version, changelog and news | |
67 | - name: Increment version and update changelogs | |
68 | run: | | |
69 | arguments= | |
70 | if [[ ${{ github.event.inputs.update_news }} == true ]] ; | |
71 | then | |
72 | arguments=$(echo $arguments && echo --update-news) | |
73 | fi | |
74 | if [[ ${{ github.event.inputs.add_date }} == true ]] ; | |
75 | then | |
76 | arguments=$(echo $arguments && echo --add-date) | |
77 | fi | |
78 | python3 ../scripts/changelog_and_release.py ${{ github.event.inputs.version_type }} ${{ github.event.inputs.changelog_text }} $arguments | |
79 | working-directory: ${{ github.event.repository.name }} | |
80 | ||
81 | # Create the variables required by the following steps | |
82 | # - steps.required-variables.outputs.changes: latest entry in the changelog.txt (if exists), or addon.xml.in news element | |
83 | # - steps.required-variables.outputs.version: version element from addon.xml.in | |
84 | # - steps.required-variables.outputs.branch: branch of the triggering ref | |
85 | # - steps.required-variables.outputs.today: today's date in format '%Y-%m-%d' | |
86 | - name: Get required variables | |
87 | id: required-variables | |
88 | run: | | |
89 | changes=$(cat "$(find . -name changelog.txt)" | awk -v RS= 'NR==1') | |
90 | if [ -z "$changes" ] ; | |
91 | then | |
92 | changes=$(xmlstarlet fo -R "$(find . -name addon.xml.in)" | xmlstarlet sel -t -v 'string(/addon/extension/news)' | awk -v RS= 'NR==1') | |
93 | fi | |
94 | changes="${changes//'%'/'%25'}" | |
95 | changes="${changes//$'\n'/'%0A'}" | |
96 | changes="${changes//$'\r'/'%0D'}" | |
97 | changes="${changes//$'\\n'/'%0A'}" | |
98 | changes="${changes//$'\\r'/'%0D'}" | |
99 | echo ::set-output name=changes::$changes | |
100 | version=$(xmlstarlet fo -R "$(find . -name addon.xml.in)" | xmlstarlet sel -t -v 'string(/addon/@version)') | |
101 | echo ::set-output name=version::$version | |
102 | branch=$(echo ${GITHUB_REF#refs/heads/}) | |
103 | echo ::set-output name=branch::$branch | |
104 | echo ::set-output name=today::$(date +'%Y-%m-%d') | |
105 | working-directory: ${{ github.event.repository.name }} | |
106 | ||
107 | # Create a commit of the incremented version and changelog, news changes | |
108 | # Commit message (add_date=false): changelog and version v{steps.required-variables.outputs.version} | |
109 | # Commit message (add_date=true): changelog and version v{steps.required-variables.outputs.version} ({steps.required-variables.outputs.today}) | |
110 | - name: Commit changes | |
111 | run: | | |
112 | git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com" | |
113 | git config --local user.name "github-actions[bot]" | |
114 | commit_message="changelog and version v${{ steps.required-variables.outputs.version }}" | |
115 | if [[ ${{ github.event.inputs.add_date }} == true ]] ; | |
116 | then | |
117 | commit_message="$commit_message (${{ steps.required-variables.outputs.today }})" | |
118 | fi | |
119 | git commit -m "$commit_message" -a | |
120 | working-directory: ${{ github.event.repository.name }} | |
121 | ||
122 | # Push the commit(s) created above to the triggering branch | |
123 | - name: Push changes | |
124 | uses: ad-m/github-push-action@master | |
125 | with: | |
126 | branch: ${{ github.ref }} | |
127 | directory: ${{ github.event.repository.name }} | |
128 | ||
129 | # Sleep for 60 seconds to allow for any delays in the push | |
130 | - name: Sleep for 60 seconds | |
131 | run: sleep 60s | |
132 | shell: bash | |
133 | ||
134 | # Create a release at {steps.required-variables.outputs.branch} | |
135 | # - tag and release name format: {steps.required-variables.outputs.version}-{steps.required-variables.outputs.branch} ie. 20.0.0-Nexus | |
136 | # - release body: {steps.required-variables.outputs.changes} | |
137 | - name: Create Release | |
138 | id: create-release | |
139 | uses: actions/create-release@v1 | |
140 | env: | |
141 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
142 | with: | |
143 | tag_name: ${{ steps.required-variables.outputs.version }}-${{ steps.required-variables.outputs.branch }} | |
144 | release_name: ${{ steps.required-variables.outputs.version }}-${{ steps.required-variables.outputs.branch }} | |
145 | body: ${{ steps.required-variables.outputs.changes }} | |
146 | draft: false | |
147 | prerelease: false | |
148 | commitish: ${{ steps.required-variables.outputs.branch }} |
0 | name: Increment version when languages are updated | |
1 | ||
2 | on: | |
3 | push: | |
4 | branches: [ Matrix, Nexus ] | |
5 | paths: | |
6 | - '**resource.language.**strings.po' | |
7 | ||
8 | jobs: | |
9 | default: | |
10 | if: github.repository == 'kodi-pvr/pvr.vuplus' | |
11 | runs-on: ubuntu-latest | |
12 | name: Increment add-on version when languages are updated | |
13 | ||
14 | steps: | |
15 | ||
16 | - name: Checkout Repository | |
17 | uses: actions/checkout@v2 | |
18 | with: | |
19 | fetch-depth: 0 | |
20 | path: ${{ github.event.repository.name }} | |
21 | ||
22 | - name: Checkout Scripts | |
23 | uses: actions/checkout@v2 | |
24 | with: | |
25 | fetch-depth: 0 | |
26 | repository: xbmc/weblate-supplementary-scripts | |
27 | path: scripts | |
28 | ||
29 | - name: Set up Python | |
30 | uses: actions/setup-python@v2 | |
31 | with: | |
32 | python-version: '3.9' | |
33 | ||
34 | - name: Get changed files | |
35 | uses: trilom/file-changes-action@v1.2.4 | |
36 | ||
37 | - name: Increment add-on version | |
38 | run: | | |
39 | python3 ../scripts/binary/increment_version.py $HOME/files.json -c -n | |
40 | working-directory: ${{ github.event.repository.name }} | |
41 | ||
42 | - name: Install dependencies | |
43 | run: | | |
44 | sudo apt-get install libxml2-utils xmlstarlet | |
45 | ||
46 | - name: Get required variables | |
47 | id: required-variables | |
48 | run: | | |
49 | version=$(xmlstarlet fo -R "$(find . -name addon.xml.in)" | xmlstarlet sel -t -v 'string(/addon/@version)') | |
50 | echo ::set-output name=version::$version | |
51 | working-directory: ${{ github.event.repository.name }} | |
52 | ||
53 | - name: Create PR for incrementing add-on versions | |
54 | uses: peter-evans/create-pull-request@v3.10.0 | |
55 | with: | |
56 | commit-message: Add-on version incremented to ${{ steps.required-variables.outputs.version }} from Weblate | |
57 | title: Add-on version incremented to ${{ steps.required-variables.outputs.version }} from Weblate | |
58 | body: Add-on version incremented triggered by ${{ github.sha }} | |
59 | branch: inc-ver | |
60 | delete-branch: true | |
61 | path: ./${{ github.event.repository.name }} |
0 | name: Make Release | |
1 | # Create a release on the given branch | |
2 | # Release and tag name format will be <version>-<branch> | |
3 | # The body of the release will be created from the changelog.txt or news element in the addon.xml.in | |
4 | ||
5 | on: workflow_dispatch | |
6 | ||
7 | jobs: | |
8 | default: | |
9 | runs-on: ubuntu-latest | |
10 | name: Make Release | |
11 | ||
12 | steps: | |
13 | ||
14 | # Checkout the current repository into a directory (repositories name) | |
15 | - name: Checkout Repository | |
16 | uses: actions/checkout@v2 | |
17 | with: | |
18 | fetch-depth: 0 | |
19 | path: ${{ github.event.repository.name }} | |
20 | ||
21 | # Install all dependencies required by the following steps | |
22 | # - libxml2-utils, xmlstarlet: reading news and version from addon.xml.in | |
23 | - name: Install dependencies | |
24 | run: | | |
25 | sudo apt-get install libxml2-utils xmlstarlet | |
26 | ||
27 | # Create the variables required by the following steps | |
28 | # - steps.required-variables.outputs.changes: latest entry in the changelog.txt (if exists), or addon.xml.in news element | |
29 | # - steps.required-variables.outputs.version: version element from addon.xml.in | |
30 | # - steps.required-variables.outputs.branch: branch of the triggering ref | |
31 | - name: Get required variables | |
32 | id: required-variables | |
33 | run: | | |
34 | changes=$(cat "$(find . -name changelog.txt)" | awk -v RS= 'NR==1') | |
35 | if [ -z "$changes" ] ; | |
36 | then | |
37 | changes=$(xmlstarlet fo -R "$(find . -name addon.xml.in)" | xmlstarlet sel -t -v 'string(/addon/extension/news)' | awk -v RS= 'NR==1') | |
38 | fi | |
39 | changes="${changes//'%'/'%25'}" | |
40 | changes="${changes//$'\n'/'%0A'}" | |
41 | changes="${changes//$'\r'/'%0D'}" | |
42 | changes="${changes//$'\\n'/'%0A'}" | |
43 | changes="${changes//$'\\r'/'%0D'}" | |
44 | echo ::set-output name=changes::$changes | |
45 | version=$(xmlstarlet fo -R "$(find . -name addon.xml.in)" | xmlstarlet sel -t -v 'string(/addon/@version)') | |
46 | echo ::set-output name=version::$version | |
47 | branch=$(echo ${GITHUB_REF#refs/heads/}) | |
48 | echo ::set-output name=branch::$branch | |
49 | working-directory: ${{ github.event.repository.name }} | |
50 | ||
51 | # Create a release at {steps.required-variables.outputs.branch} | |
52 | # - tag and release name format: {steps.required-variables.outputs.version}-{steps.required-variables.outputs.branch} ie. 20.0.0-Nexus | |
53 | # - release body: {steps.required-variables.outputs.changes} | |
54 | - name: Create Release | |
55 | id: create-release | |
56 | uses: actions/create-release@v1 | |
57 | env: | |
58 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
59 | with: | |
60 | tag_name: ${{ steps.required-variables.outputs.version }}-${{ steps.required-variables.outputs.branch }} | |
61 | release_name: ${{ steps.required-variables.outputs.version }}-${{ steps.required-variables.outputs.branch }} | |
62 | body: ${{ steps.required-variables.outputs.changes }} | |
63 | draft: false | |
64 | prerelease: false | |
65 | commitish: ${{ steps.required-variables.outputs.branch }} |
0 | name: Sync addon metadata translations | |
1 | ||
2 | on: | |
3 | push: | |
4 | branches: [ Matrix, Nexus ] | |
5 | paths: | |
6 | - '**addon.xml.in' | |
7 | - '**resource.language.**strings.po' | |
8 | ||
9 | jobs: | |
10 | default: | |
11 | if: github.repository == 'kodi-pvr/pvr.vuplus' | |
12 | runs-on: ubuntu-latest | |
13 | ||
14 | strategy: | |
15 | ||
16 | fail-fast: false | |
17 | matrix: | |
18 | python-version: [ 3.9 ] | |
19 | ||
20 | steps: | |
21 | ||
22 | - name: Checkout repository | |
23 | uses: actions/checkout@v2 | |
24 | with: | |
25 | path: project | |
26 | ||
27 | - name: Checkout sync_addon_metadata_translations repository | |
28 | uses: actions/checkout@v2 | |
29 | with: | |
30 | repository: xbmc/sync_addon_metadata_translations | |
31 | path: sync_addon_metadata_translations | |
32 | ||
33 | - name: Set up Python ${{ matrix.python-version }} | |
34 | uses: actions/setup-python@v2 | |
35 | with: | |
36 | python-version: ${{ matrix.python-version }} | |
37 | ||
38 | - name: Install dependencies | |
39 | run: | | |
40 | python -m pip install --upgrade pip | |
41 | python -m pip install sync_addon_metadata_translations/ | |
42 | ||
43 | - name: Run sync-addon-metadata-translations | |
44 | run: | | |
45 | sync-addon-metadata-translations | |
46 | working-directory: ./project | |
47 | ||
48 | - name: Create PR for sync-addon-metadata-translations changes | |
49 | uses: peter-evans/create-pull-request@v3.10.0 | |
50 | with: | |
51 | commit-message: Sync of addon metadata translations | |
52 | title: Sync of addon metadata translations | |
53 | body: Sync of addon metadata translations triggered by ${{ github.sha }} | |
54 | branch: amt-sync | |
55 | delete-branch: true | |
56 | path: ./project |
0 | # build artifacts | |
1 | build/ | |
2 | pvr.*/addon.xml | |
3 | ||
4 | # Debian build files | |
5 | debian/changelog | |
6 | debian/files | |
7 | debian/*.log | |
8 | debian/*.substvars | |
9 | debian/.debhelper/ | |
10 | debian/tmp/ | |
11 | debian/kodi-pvr-*/ | |
12 | obj-x86_64-linux-gnu/ | |
13 | ||
14 | # commonly used editors | |
15 | # vim | |
16 | *.swp | |
17 | ||
18 | # Eclipse | |
19 | *.project | |
20 | *.cproject | |
21 | .classpath | |
22 | *.sublime-* | |
23 | .settings/ | |
24 | ||
25 | # KDevelop 4 | |
26 | *.kdev4 | |
27 | ||
28 | # gedit | |
29 | *~ | |
30 | ||
31 | # CLion | |
32 | /.idea | |
33 | ||
34 | # clion | |
35 | .idea/ | |
36 | ||
37 | # to prevent add after a "git format-patch VALUE" and "git add ." call | |
38 | /*.patch | |
39 | ||
40 | # Visual Studio Code | |
41 | .vscode | |
42 | ||
43 | # to prevent add if project code opened by Visual Studio over CMake file | |
44 | .vs/ | |
45 | ||
46 | # General MacOS | |
47 | .DS_Store | |
48 | .AppleDouble | |
49 | .LSOverride |
0 | 0 | <?xml version="1.0" encoding="UTF-8"?> |
1 | 1 | <addon |
2 | 2 | id="pvr.vuplus" |
3 | version="20.4.1" | |
3 | version="20.4.2" | |
4 | 4 | name="Enigma2 Client" |
5 | 5 | provider-name="Joerg Dembski and Ross Nicholson"> |
6 | 6 | <requires>@ADDON_DEPENDS@ |