Metadata-Version: 2.1
Name: logandprint
Version: 1.0.0
Summary: A simple logging package that helps you to log what is happening in your application.
Home-page: https://github.com/guisaldanha/logandprint
Author: Guilherme Saldanha
Author-email: guisaldanha@gmail.com
License: UNKNOWN
Project-URL: Documentation, https://github.com/guisaldanha/logandprint/README.md
Project-URL: Source, https://github.com/guisaldanha/logandprint
Project-URL: Tracker, https://github.com/guisaldanha/logandprint/issues
Keywords: python,log,logging,print,file
Platform: UNKNOWN
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Intended Audience :: Developers
Description-Content-Type: text/markdown
License-File: LICENSE

# Log and Print

A simple logging package that helps you to log what is happening in your application.

## Installation

You can install `LogAndPrint` using pip:

```bash
pip install logandprint
```

## Usage

To start logging it is as simple as importing the logandprint object and issuing the logging commands:

### write

To write a message to the log:

```python
import logandprint as log

log.write("This is a message that will be logged")
```

### setLogFile

By default, the log is saved in the `log.log` file in the current directory. But you can change the log file by using the `setLogFile` function.

```python
log.setLogFile("./logs/myLogFile.log")
```

The log packet will not be printed to the console. You can change this by setting `debugMode` to True.

```python
log.debubMode(True)
```

To stop printing to the console, change the `debugMode` setting to False. Don't worry, the log file will still be writing.

```python
log.debugMode(False)
```

To disable the `logg` you can call the `disable` function

```python
log.disable()
```

And to enable it again you can call the `enable` function

```python
log.enable()
```

## Author

- Guilherme Saldanha

## Copyright

This software is free to use and distribute. You can use it for any purpose, but please give credit to the original author.

For more info see LICENSE file.


