Simplify remote directory creation to unconditional mkdir -p
Intent: Replace the conditional shell logic that checked for existing symlinks before creating staged output directories with a single unconditional `mkdir -p` call covering all eight directories. This removes the `if [ ! -e ... ] && [ ! -L ... ]` guards that previously protected symlinked staged payload paths, since symlinks are no longer used.
Affected files: crates/pikaci/src/executor.rs
@@ -1923,12 +1923,7 @@ fn ensure_remote_linux_vm_directories(
- concat!(
- "set -euo pipefail; ",
- "mkdir -p {} {} {} {} {} {}; ",
- "if [ ! -e {} ] && [ ! -L {} ]; then mkdir -p {}; fi; ",
- "if [ ! -e {} ] && [ ! -L {} ]; then mkdir -p {}; fi"
- ),
+ "set -euo pipefail; mkdir -p {} {} {} {} {} {} {} {}",
@@ -1936,10 +1931,6 @@ fn ensure_remote_linux_vm_directories(
- shell_single_quote(&shared.remote_workspace_deps_dir.display().to_string()),
- shell_single_quote(&shared.remote_workspace_deps_dir.display().to_string()),
- shell_single_quote(&shared.remote_workspace_build_dir.display().to_string()),
- shell_single_quote(&shared.remote_workspace_build_dir.display().to_string()),
The old ensure_remote_linux_vm_directories built a shell command with a concat! macro that assembled three clauses:
mkdir -pfor the six core directories.- A conditional
if [ ! -e ... ] && [ ! -L ... ]; then mkdir -p ...; fiforworkspace-deps. - The same conditional for
workspace-build.
The conditionals existed because a prior step could install symlinks at those paths (pointing to local staged payload directories on localhost). Creating the directory over an existing symlink would have been an error.
With symlinks removed from the workflow, these guards are unnecessary. The format string collapses to a single mkdir -p with eight positional arguments, and the duplicated shell_single_quote calls for the conditional branches are deleted. The two staged output paths (remote_workspace_deps_dir, remote_workspace_build_dir) are now created unconditionally alongside every other directory.