Skip to content

Commit 55f3a16

Browse files
committed
ci: improve SSH directory creation logic
Update the GitHub Actions workflow to ensure the ~/.ssh directory is created only if it does not already exist. This prevents unnecessary output and maintains clarity in the workflow logs.
1 parent fd2d528 commit 55f3a16

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

.github/workflows/ci-cd.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ jobs:
6464
6565
- name: Add GitHub to known_hosts
6666
run: |
67-
mkdir -p ~/.ssh || echo "dir exists"
67+
if [ ! -d ~/.ssh ]; then mkdir -p ~/.ssh; else echo "dir exists"; fi
6868
ssh-keyscan github.com >> ~/.ssh/known_hosts
6969
7070
- name: add net git fetch

0 commit comments

Comments
 (0)