Created
December 20, 2025 16:17
-
-
Save floehopper/7dc8a32d0f8a56d2430372f0ba40d00d to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env zsh | |
| SRC_ROOT="???" | |
| DST_ROOT="???" | |
| find "$SRC_ROOT" \ | |
| \( -type d -name node_modules -prune \) -o \ | |
| \( -mindepth 4 -maxdepth 4 -type f -name "master.key" \ | |
| -print \) | while read -r file; do | |
| relpath="${file#$SRC_ROOT/}" | |
| dest="$DST_ROOT/$relpath" | |
| mkdir -p "$(dirname "$dest")" | |
| cp "$file" "$dest" | |
| done | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment