Created
April 2, 2023 15:32
-
-
Save andrewd-uriux/709dfe1279552001cf281cc801bbd5b2 to your computer and use it in GitHub Desktop.
get-dot-files-for-mac
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 bash | |
##ls -ld ~/.?* | tr -s ' ' | cut -d' ' -f9 | grep -v | |
##'history\|.ssh\|Trash\|sock\|dump\|Google\|npm\|DS_Store\|docker\|virtual\|CFUser\|lima\|nvm\|vscode' | |
#| xargs -I% sh -c 'FILE="%" && echo copying $FILE && | |
##echo -r $FILE ./home' | |
# copy dots | |
echo 'getting dot files...' | |
ls -ld ~/.?* | tr -s ' ' | cut -d' ' -f9 | grep -v '\.\.\|history\|.ssh\|.aws-sam\|AWSVPNClient\|Trash\|sock\|dump\|Google\|npm\|.DS_Store\|docker\|virtual\|CFUser\|lima\|nvm\|vscode\|cache\|.oh-my-zsh' | xargs -I% sh -c 'FILE="%" && echo copying $FILE && cp -r $FILE ./home' | |
echo 'getting non-dot files' | |
# copy non-dot | |
declare -a SOURCE_FILES=( | |
~/bin | |
) | |
for f in "${SOURCE_FILES[@]}"; do | |
: | |
cp -rf $f ./home/ | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment