Forked from sankitch/search-document-by-percol.zsh
Last active
September 4, 2015 10:31
-
-
Save opexxx/c205a7b3ff021e5c6de1 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
| function search-document-by-percol() { | |
| DOCUMENT_DIR="$HOME/Dropbox/Documents/ $HOME/Desktop/ $HOME/Google\ ドライブ" | |
| SELECTED_FILE=$(echo $DOCUMENT_DIR | xargs find | \ | |
| grep -E "\.(xlsx|xls|pptx|ppt|docx|doc|pdf|txt|odp|odt|ods|xmind|mm|glink|gsheet)$" | percol --match-method migemo) | |
| if [ $? -eq 0 ]; then | |
| cygstart $SELECTED_FILE | |
| fi | |
| } | |
| alias sd='search-document-by-percol' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment