Last active
August 29, 2015 14:17
-
-
Save masakiplus/44bdc14cf2e5917190d8 to your computer and use it in GitHub Desktop.
auto mail sender
This file contains 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
@echo off | |
rem smail.exe installation required | |
set pdfpath=%1 | |
set smailpath="exeplace" | |
set smtp=smtp.gmail.com | |
set from=hoge@gmail.com | |
set to="hoge@gmail.com" | |
for /f "delims=;" %%i in ('dir /b /od %pdfpath%\*.pdf') do ( | |
echo PDFfile: %%i | |
%smailpath%smail.exe -d -h%smtp% -f%from% -sScan:%%i %to% -a%pdfpath%\%%i | |
echo %%i was sent to %to% | |
del %pdfpath%\%%i /Q | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment