Merge pull request #814 from nextcloud/release/0.9.5

Create Release 0.9.5
This commit is contained in:
Christian 2021-10-16 15:55:58 +02:00 коммит произвёл GitHub
Родитель 4b090c20d5 3494885fc3
Коммит 4675a63bd3
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
23 изменённых файлов: 214 добавлений и 52 удалений

6
.github/actions/deploy/create-version.sh поставляемый
Просмотреть файл

@ -57,8 +57,10 @@ git tag "v$version"
git checkout $master_branch
git merge --no-ff $stable_branch
git push origin $stable_branch
git push origin $master_branch
git remote add tokenized "https://nextcloud-cookbook-bot:$BOT_TOKEN@github.com/nextcloud/cookbook.git"
git push tokenized $stable_branch
git push tokenized $master_branch
git push origin "v$version"
echo "::set-output name=version::$version"

7
.github/workflows/deploy-appstore.yml поставляемый
Просмотреть файл

@ -1,5 +1,5 @@
name: Deploy testing
name: Deploy to Appstore
on:
push:
@ -17,6 +17,8 @@ jobs:
shell: bash
working-directory: cookbook
if: github.actor != 'nextcloud-cookbook-bot'
steps:
- name: Checkout the project
uses: actions/checkout@v2
@ -28,9 +30,12 @@ jobs:
- name: Bump the version
id: bump
run: ./.github/actions/deploy/create-version.sh
env:
BOT_TOKEN: ${{ secrets.COOKBOOK_BOT_TOKEN }}
- name: Install the NPM packages
run: npm install
- name: Build NPM
run: npm run build

48
.github/workflows/publish-test-results.yml поставляемый Normal file
Просмотреть файл

@ -0,0 +1,48 @@
name: Annotate test results
on:
workflow_run:
workflows:
- "CI"
types:
- completed
jobs:
test-results:
runs-on: ubuntu-latest
name: Test results
if: >-
github.event.workflow_run.conclusion != 'skipped' &&
github.event.workflow_run.event == 'pull_request'
steps:
# - name: Debug output
# env:
# EVENT: ${{ toJSON(github.event) }}
# run: |
# echo "$EVENT"
- name: Download and Extract Artifacts
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
run: |
mkdir -p artifacts && cd artifacts
artifacts_url=${{ github.event.workflow_run.artifacts_url }}
gh api "$artifacts_url" -q '.artifacts[] | [.name, .archive_download_url] | @tsv' | while read artifact
do
IFS=$'\t' read name url <<< "$artifact"
gh api $url > "$name.zip"
unzip -d "$name" "$name.zip"
done
- name: Publish Unit Test Results
uses: EnricoMi/publish-unit-test-result-action@v1
with:
commit: ${{ github.event.workflow_run.head_sha }}
event_file: artifacts/Event File/event.json
event_name: ${{ github.event.workflow_run.event }}
files: "artifacts/Junit test log files*/*.xml"

130
.github/workflows/tests.yml поставляемый
Просмотреть файл

@ -1,8 +1,11 @@
name: CI-tests
name: CI
on:
push:
paths-ignore:
- 'docs/**'
- 'l10n/**'
pull_request:
jobs:
@ -23,7 +26,7 @@ jobs:
- name: Install Composer
shell: bash
run: >-
wget https://github.com/composer/getcomposer.org/raw/master/web/installer -O - -q |
wget https://github.com/composer/getcomposer.org/raw/main/web/installer -O - -q |
php -- --quiet
- name: Install PHP packages
@ -174,7 +177,7 @@ jobs:
server: ${{ matrix.httpServer }}
coreVersion: ${{ matrix.coreVersion }}
- name: Upload the log file
- name: Upload the log file as artifact
uses: actions/upload-artifact@v2
with:
name: Nextcloud-logs (${{matrix.database}}, ${{matrix.coreVersion}}, ${{matrix.httpServer}}, ${{matrix.phpVersion}})
@ -186,22 +189,6 @@ jobs:
echo "Exiting with ${{ env.test_result }}" ;
exit "${{ env.test_result }}"
- name: Upload the coverage reports to codecov.io
shell: bash
run: >-
bash <(curl -s https://codecov.io/bash)
-F unittests
-f .github/actions/run-tests/volumes/coverage/latest/coverage.unit.xml
-R .
-X gcov
&&
bash <(curl -s https://codecov.io/bash)
-F integration
-f .github/actions/run-tests/volumes/coverage/latest/coverage.integration.xml
-R .
-X gcov
if: ${{ steps.run-tests.outputs.silentFail == 'false' }}
- name: Copy coverage-reports into non-link folder
shell: bash
run: >-
@ -209,14 +196,14 @@ jobs:
rsync -a .github/actions/run-tests/volumes/coverage/latest/ /tmp/coverage
if: ${{ steps.run-tests.outputs.silentFail == 'false' }}
- name: Upload the code coverage report (unit tests)
- name: Upload the code coverage report (unit tests) as artifacts
uses: actions/upload-artifact@v2
with:
name: Code coverage (HTML) (${{matrix.database}}, ${{matrix.coreVersion}}, ${{matrix.httpServer}}, ${{matrix.phpVersion}})
path: "/tmp/coverage"
if: ${{ steps.run-tests.outputs.silentFail == 'false' }}
- name: Upload the junit log file artifact
- name: Upload the junit log file artifact as artifact
uses: actions/upload-artifact@v2
with:
name: Junit test log files (${{matrix.database}}, ${{matrix.coreVersion}}, ${{matrix.httpServer}}, ${{matrix.phpVersion}})
@ -224,6 +211,74 @@ jobs:
if: always()
upload-codecov:
name: Upload artifacts to codecov.io
needs:
- unit-tests
runs-on: ubuntu-latest
steps:
- name: Create folder structure
run: mkdir artifacts code unit-coverage integration-coverage
- name: Download artifacts
uses: actions/download-artifact@v2.0.10
with:
path: artifacts
- name: Checkout of code base
uses: actions/checkout@v2
with:
path: code
fetch-depth: 2
- name: Download the uploader
run: |
curl https://keybase.io/codecovsecurity/pgp_keys.asc | gpg --no-default-keyring --keyring trustedkeys.gpg --import
curl -Os https://uploader.codecov.io/latest/linux/codecov
curl -Os https://uploader.codecov.io/latest/linux/codecov.SHA256SUM
curl -Os https://uploader.codecov.io/latest/linux/codecov.SHA256SUM.sig
gpgv codecov.SHA256SUM.sig codecov.SHA256SUM
shasum -a 256 -c codecov.SHA256SUM
chmod +x codecov
- name: Copy Coverage reports to separate folders
run: |
cd artifacts
for i in Code*
do
if [ -f "$i/coverage.unit.xml" ]; then
mkdir -p "../unit-coverage/$i"
cp "$i/coverage.unit.xml" "../unit-coverage/$i/coverage.xml"
fi
if [ -f "$i/coverage.integration.xml" ]; then
mkdir -p "../integration-coverage/$i"
cp "$i/coverage.integration.xml" "../integration-coverage/$i/coverage.xml"
fi
done
- name: Show file structure
run: ls -lR unit-coverage integration-coverage
- name: Upload unit test codecov reports
run: >-
./codecov
-F unittests
-s unit-coverage
-R code
-X gcov
-v
- name: Upload integration test codecov reports
run: >-
./codecov
-F integration
-s integration-coverage
-R code
-X gcov
-v
source-package:
name: Create source code artifacts
needs:
@ -262,30 +317,15 @@ jobs:
name: cookbook-appstore
path: /tmp/appstore.tar.gz
annotate-test-results:
name: Annotate the test results
needs:
- unit-tests
event_file:
name: "Upload Event File"
runs-on: ubuntu-latest
if: success() || failure()
steps:
- name: Download artifact
uses: actions/download-artifact@v2
#with:
#name: Junit test log files
#path: .
- name: List files
shell: bash
run: ls -lR
#if: always()
- name: Publish Unit Test Results
uses: EnricoMi/publish-unit-test-result-action@v1.19
with:
files: "Junit test log files*/*.xml"
test_changes_limit: 100
#if: always()
- name: Upload
uses: actions/upload-artifact@v2
with:
name: Event File
path: ${{ github.event_path }}
retention-days: 1

Просмотреть файл

@ -1,8 +1,14 @@
#!/bin/sh
if [ -e 'vendor/bin/php-cs-fixer' ]; then
lines_before=`git stash list | wc -l`
git stash push --keep-index
lines_after=`git stash list | wc -l`
composer cs:check || { echo "The PHP code is not validly formatted."; exit 1; }
git stash pop
if [ $lines_before -lt $lines_after ]; then
git stash pop
fi
fi

Просмотреть файл

@ -1,5 +1,21 @@
## [Unreleased]
## 0.9.5 - 2021-10-15
### Fixed
- Fix empty Category
[#805](https://github.com/nextcloud/cookbook/pull/805) @jotoeri
- Fix CI test scripts
[#809](https://github.com/nextcloud/cookbook/pull/809) @christianlupus
- Update stylelint-config-prettier
[#807](https://github.com/nextcloud/cookbook/pull/807) @christianlupus
- Correct unit testing for dependabot and forked branches
[#811](https://github.com/nextcloud/cookbook/pull/811) @christianlupus
- Updated codecov parser to binary version (fix #810)
[#813](https://github.com/nextcloud/cookbook/pull/813) @christianlupus
- Allow bot user to push to stable branch
[#812](https://github.com/nextcloud/cookbook/pull/812) @christianlupus
## 0.9.4 - 2021-09-29

Просмотреть файл

@ -272,7 +272,7 @@ class DbCacheService {
* @return string|null The category name of null if no category was found.
*/
private function getJSONCategory(array $json): ?string {
if (!isset($json['recipeCategory'])) {
if (!isset($json['recipeCategory']) || strlen(trim($json['recipeCategory'])) == 0) {
return null;
}

Просмотреть файл

@ -46,7 +46,7 @@
"babel-loader": "^8.1.0",
"compression-webpack-plugin": "^9.0.0",
"css-loader": "^6.0.0",
"eslint": "^7.20.0",
"eslint": "^8.0.1",
"eslint-config-airbnb-base": "^14.2.1",
"eslint-config-prettier": "^8.0.0",
"eslint-plugin-import": "^2.22.1",
@ -56,7 +56,7 @@
"prettier": "^2.2.1",
"stylelint": "^13.12.0",
"stylelint-config-idiomatic-order": "^8.1.0",
"stylelint-config-prettier": "^8.0.2",
"stylelint-config-prettier": "^9.0.3",
"stylelint-config-sass-guidelines": "^8.0.0",
"stylelint-config-standard": "^22.0.0",
"stylelint-scss": "^3.19.0",

Просмотреть файл

@ -74,6 +74,7 @@ export default {
div {
margin: 20px 5px;
}
.message {
font-size: x-large;
font-weight: bold;

Просмотреть файл

@ -42,12 +42,15 @@ export default {
padding: 0 !important;
margin-left: 0 !important;
}
#app-navigation-vue {
display: none !important;
}
#header {
display: none !important;
}
a:link::after,
a:visited::after {
content: " [" attr(href) "] ";

Просмотреть файл

@ -244,6 +244,7 @@ export default {
padding: 0;
border-radius: var(--border-radius);
}
#app-settings .button p {
margin: auto;
font-size: 13px;

Просмотреть файл

@ -403,6 +403,7 @@ li .controls > button:last-child {
border-bottom-right-radius: var(--border-radius);
border-top-right-radius: var(--border-radius);
}
li .controls > button:last-child:not(:hover):not(:focus) {
border-right-color: var(--color-border-dark);
}
@ -427,6 +428,7 @@ li .controls > button:last-child:not(:hover):not(:focus) {
clear: both;
content: "";
}
.step-number {
position: absolute;
top: 0;

Просмотреть файл

@ -45,6 +45,7 @@ fieldset > * {
float: none;
}
}
fieldset > label {
display: inline-block;
width: 10em;

Просмотреть файл

@ -235,6 +235,7 @@ fieldset > * {
float: none;
}
}
fieldset > label {
display: inline-block;
width: 16em;

Просмотреть файл

@ -162,6 +162,7 @@ picture .full-resolution.image-loaded {
from {
opacity: 0;
}
to {
opacity: 1;
}
@ -171,6 +172,7 @@ picture .full-resolution.image-loaded {
from {
filter: blur(0.5rem);
}
to {
filter: blur(0);
}

Просмотреть файл

@ -78,12 +78,14 @@ export default {
max-width: 100%;
margin: 0.5rem 1rem 1rem;
}
.recipe-card a {
display: block;
height: 105px;
border-radius: 3px;
box-shadow: 0 0 3px #aaa;
}
.recipe-card a:hover {
box-shadow: 0 0 5px #888;
}
@ -120,6 +122,7 @@ export default {
.recipe-card .recipe-info-date {
display: flex;
}
.recipe-info-date-icon {
height: 1.4ex;
min-height: 0;

Просмотреть файл

@ -727,6 +727,7 @@ export default {
background-color: var(--color-main-background);
opacity: 0.75;
}
.overlay.hidden {
display: none;
}

Просмотреть файл

@ -37,16 +37,19 @@ div {
margin-bottom: 1rem;
text-align: center;
}
img {
width: 100%;
max-width: 950px;
background-color: #bebdbd;
cursor: pointer;
}
.collapsed {
overflow: hidden;
height: 40vh;
}
.collapsed img {
display: block;
margin: 0 auto;

Просмотреть файл

@ -36,6 +36,7 @@ li {
cursor: pointer;
white-space: pre-line;
}
li::before {
position: absolute;
top: 0;
@ -52,12 +53,15 @@ li::before {
outline: none;
text-align: center;
}
li:hover::before {
border-color: var(--color-primary-element);
}
.done::before {
content: "✔";
}
li span,
li input[type="checkbox"] {
display: inline-block;

Просмотреть файл

@ -322,6 +322,7 @@ export default {
.recipe-sorting-item-placeholder {
display: block;
}
.ordering-item-icon {
margin-right: 0.5em;
}

Просмотреть файл

@ -258,6 +258,7 @@ export default {
font-size: 8px;
vertical-align: bottom;
}
.ordering-button {
padding: 2px 6px;
}

Просмотреть файл

@ -142,6 +142,7 @@ export default {
font-size: 1.2rem;
text-align: center;
}
.time button {
position: absolute;
top: 0;
@ -150,6 +151,7 @@ export default {
height: 36px;
transform: translate(-50%, -50%);
}
.time h4 {
padding: 0.5rem;
border-bottom: 1px solid var(--color-border-dark);

Просмотреть файл

@ -561,12 +561,15 @@ export default {
display: flex;
flex-wrap: wrap;
}
.header > .image {
flex: 600px 0 0;
}
.header > .meta {
margin: 0 10px;
}
.header a::after {
content: "";
}
@ -585,12 +588,15 @@ export default {
.meta {
margin: 0 1rem;
}
.dates {
font-size: 0.9em;
}
.date {
margin-right: 1.5em;
}
.date-icon {
display: inline-block;
margin-right: 0.2em;
@ -598,13 +604,16 @@ export default {
background-size: 1em;
vertical-align: middle;
}
.date-text {
vertical-align: middle;
}
.description {
font-style: italic;
white-space: pre-line;
}
.details p {
margin: 0.5em 0;
}
@ -639,6 +648,7 @@ export default {
font-size: 1.2rem;
text-align: center;
}
.times .time button {
position: absolute;
top: 0;
@ -647,6 +657,7 @@ export default {
height: 36px;
transform: translate(-50%, -50%);
}
.times .time h4 {
padding: 0.5rem;
border-bottom: 1px solid var(--color-border-dark);
@ -661,6 +672,7 @@ export default {
section {
margin-bottom: 1rem;
}
section::after {
display: table;
clear: both;
@ -692,11 +704,13 @@ aside {
aside ul {
list-style-type: none;
}
aside ul li {
margin-bottom: 0.75ex;
margin-left: 1em;
line-height: 2.5ex;
}
aside ul li span,
aside ul li input[type="checkbox"] {
display: inline-block;
@ -749,12 +763,14 @@ main {
counter-reset: instruction-counter;
list-style: none;
}
.instructions .instruction {
margin-bottom: 2rem;
clear: both;
counter-increment: instruction-counter;
cursor: pointer;
}
.instructions .instruction::before {
display: block;
width: 36px;
@ -771,9 +787,11 @@ main {
outline: none;
text-align: center;
}
.instructions .instruction:hover::before {
border-color: var(--color-primary-element);
}
.instructions .instruction.done::before {
content: "✔";
}
@ -784,6 +802,7 @@ main {
color: var(--color-text-maxcontrast);
font-weight: 450;
}
.recipe-reference-inline:hover {
color: var(--color-main-text);
}