semvec/pypi-packages huggingface dataset:
mercurio 0.10.2
Send email with python, my way
License: MIT

# Mercurio

Send email with python, my way.

Mercurio is a simple class to send email with python, managing
smtp, attachments and mimetypes, multiple recipients,
attachments with a specific content id (to html email templating)...

## Installation

Installation is as easy as run:
```pip install mercurio```

## Usage

To initialize a mercurio instance simply call it with
typical smtp parameters. No connection will be opened
at this stage, then you can initialize and reuse it
during the whole code.

```python
from mercurio import mercurio

hg = mercurio(
    host="smtp.test.com",
    port=25,
    smtp_user="myuser",
    smtp_pwd="mypwd"
)
```

To debug purposes, you can create the message and save it in a file
without send it thgrougth smtp. You can open such file
with a normal email client.

```python
message = hg.make_message(
    fromaddress="from@me.com",
    recipient="to@me.com",
    reply_to_address="reply@to.me",
    text="a long text, very long.",
    sbj="The subject, or the object?",
    attachments=[],
    cid_attachments={}
)

with open('test_email.eml', 'w') as o:
    o.write(message.as_string())
```


Send a real message is easy: use
an hg instance, and call
send method with its parameters. Note that you can
send multiple type of attachments (images, xlsx, json,
txt). Mercurio can choice the correct mime type.
You can also use attachment with a specific content
id, that can be used in html email to include
images in the body of the message.

```python
hg.send(
    fromaddress="from@me.com",
    recipients=["to@me.com"],
    reply_to_address="reply@to.me",
    text="a long text, very long.",
    sbj="The subject, or the object?",
    attachments=[],
    cid_attachments={"content_id_01": "mylogo.png"}
)
```
fastconf 1.0.0
A simple config lib
License: MIT
Keywords: config

# FastConf

Simple lib for configuration

[![pypi](https://img.shields.io/pypi/v/fastconf.svg)](https://pypi.org/project/fastconf/)

#### Install   
```
$ pip install fastconf
```


#### Example project structure

```
main.py
core/
    __init__.py
    config.py
```

**main.py**    
```python
from core import config
print('TOKEN:', config.TOKEN)
```
**core/config.py**
```python
import fastconf
TOKEN = '...'
fastconf.config(__name__)
```

#### Run project:
```
$ python main.py
TOKEN: ...
```

The **config.yml** file is created in the project root directory.

Change him:
```
TOKEN: 'MY_TOKEN'
```

#### Run again
```
$ python main.py
TOKEN: MY_TOKEN
```


`fastconf.config(name, file='config.yml', root=ROOT_DIR)`

`name` - current name of config module   
`file` - name config file    
`dir` - path to config dir