# S-Mail Cli Client
Send emails with attachments from the command line
--------------------
### Usage
#### Set your credentials
#### For Gmail to get you credentials password
1. Go to [Google Account](https://myaccount.google.com/) and click on the avatar on the top right corner and click on `Manage your Google Account`
2. Find the Security section on the left side
3. In the Signing in to Google section, Enable 2-Step Verification if not already enabled
4. In the same section, click on App passwords
5. Select `Mail` as the app and `Other` as the device and give it a name
6. Click on Generate and copy the password
```bash
$ smail credentials -p smtp.gmail.com -e myemail@gmail.com -c super-secret-password # set your credentials
```
#### Send an email with attachment
```bash
# file must be in the current directory
$ smail email -t recipient-email@gmail.com -s "Here is the pdf file" -a filename.pdf # send an email with a subject and an attachment
```