Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Modify github actions for dev base branch #6

Merged
merged 1 commit into from
Jan 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/generate-chart-readme.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
pull_request:
branches:
- main
- dev

permissions: {} # Remove all permissions by default

Expand Down
11 changes: 9 additions & 2 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
pull_request:
branches:
- main
- dev

jobs:
lint-test:
Expand All @@ -30,11 +31,17 @@ jobs:
- name: Run chart-testing (list-changed)
id: list-changed
run: |
changed=$(ct list-changed --target-branch ${{ github.event.repository.default_branch }} --config ct.yaml)
changed=$(ct list-changed --target-branch ${{ github.base_ref }} --config ct.yaml)
if [[ -n "$changed" ]]; then
echo "changed=true" >> "$GITHUB_OUTPUT"
fi

- name: Run chart-testing (lint)
if: steps.list-changed.outputs.changed == 'true'
run: ct lint --target-branch ${{ github.event.repository.default_branch }} --lint-conf lintconf.yaml --config ct.yaml
run: |
ARGS="--target-branch ${{ github.base_ref }} --lint-conf lintconf.yaml --config ct.yaml"
# Add an additional argument if the base branch is 'dev'
if [ "${{ github.base_ref }}" == "dev" ]; then
ARGS="$ARGS --check-version-increment false"
fi
ct lint $ARGS
Loading