Skip to content

Commit aa56798

Browse files
authored
Fix reusable workflow configuration (#18)
* Fix reusable workflow configuration - Add workflow_call trigger to check-version.yml, lint.yml, and test.yml - Enable these workflows to be called by ci.yml as reusable workflows - Resolve GitHub Actions workflow validation error * Bump version to 0.1.4 in README.md and sync-ssh-keys.sh * Fix ci-success job dependency on version-check - Add version-check to needs array in ci-success job - Ensure version-check.result is properly accessible - Fix empty string evaluation causing false failures
1 parent ec01f9b commit aa56798

File tree

6 files changed

+6
-3
lines changed

6 files changed

+6
-3
lines changed

.github/workflows/check-version.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ on:
88
- 'sync-ssh-keys.sh'
99
- 'users.conf'
1010
- '.github/workflows/check-version.yml'
11+
workflow_call:
1112

1213
jobs:
1314
check-version:

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
# Final status check
2424
ci-success:
2525
runs-on: ubuntu-latest
26-
needs: [lint, test]
26+
needs: [lint, test, version-check]
2727
if: always()
2828
steps:
2929
- name: Check all jobs status

.github/workflows/lint.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ on:
1515
- 'sync-ssh-keys.sh'
1616
- 'users.conf'
1717
- '.github/workflows/lint.yml'
18+
workflow_call:
1819

1920
jobs:
2021
shellcheck:

.github/workflows/test.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ on:
1818
- 'sync-ssh-keys.sh'
1919
- 'users.conf'
2020
- '.github/workflows/test.yml'
21+
workflow_call:
2122

2223
jobs:
2324
test:

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
[![Test Status](https://img.shields.io/github/actions/workflow/status/locus313/ssh-key-sync/ci.yml?style=flat-square&label=tests)](https://github.com/locus313/ssh-key-sync/actions)
55
[![License](https://img.shields.io/badge/License-MIT-blue?style=flat-square)](LICENSE)
66
[![Shell](https://img.shields.io/badge/Shell-Bash-green?style=flat-square&logo=gnu-bash)](https://www.gnu.org/software/bash/)
7-
[![Version](https://img.shields.io/badge/Version-0.1.3-orange?style=flat-square)](https://github.com/locus313/ssh-key-sync/releases)
7+
[![Version](https://img.shields.io/badge/Version-0.1.4-orange?style=flat-square)](https://github.com/locus313/ssh-key-sync/releases)
88

99
⭐ If you like this project, star it on GitHub — it helps a lot!
1010

sync-ssh-keys.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ set -euo pipefail
77
# Repository: https://github.com/locus313/ssh-key-sync
88

99
# shellcheck disable=SC2034 # planned to be used in a future release
10-
readonly SCRIPT_VERSION="0.1.3"
10+
readonly SCRIPT_VERSION="0.1.4"
1111
SCRIPT_NAME="$(basename "$0")"
1212
readonly SCRIPT_NAME
1313

0 commit comments

Comments
 (0)