-
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #5 from codeperfectplus/v1.0.0
V1.0.0
- Loading branch information
Showing
9 changed files
with
77 additions
and
15 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
# Read the Docs configuration file for Sphinx projects | ||
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details | ||
|
||
# Required | ||
version: 2 | ||
|
||
# Set the OS, Python version and other tools you might need | ||
build: | ||
os: ubuntu-22.04 | ||
tools: | ||
python: "3.12" | ||
# You can also specify other tool versions: | ||
# nodejs: "20" | ||
# rust: "1.70" | ||
# golang: "1.20" | ||
|
||
# Build documentation in the "docs/" directory with Sphinx | ||
sphinx: | ||
configuration: docs/conf.py | ||
# You can configure Sphinx to use a different builder, for instance use the dirhtml builder for simpler URLs | ||
# builder: "dirhtml" | ||
# Fail on all warnings to avoid broken references | ||
# fail_on_warning: true | ||
|
||
# Optionally build your docs in additional formats such as PDF and ePub | ||
formats: | ||
- epub | ||
|
||
# Optional but recommended, declare the Python requirements required | ||
# to build your documentation | ||
# See https://docs.readthedocs.io/en/stable/guides/reproducible-builds.html | ||
python: | ||
install: | ||
- requirements: docs/requirements.txt |
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,38 @@ | ||
Introduction | ||
============ | ||
|
||
This project is python port of Validator.js which is a library for string validation. | ||
So people who are familiar with Validator.js can easily switch to this library. | ||
It is also a good way to learn how to port a library from one language to another. | ||
I have tried to keep the code as similar as possible to the original library. | ||
if you find any bugs or have any suggestions please open an issue. | ||
if you want to contribute please open a pull request. | ||
This project is inspired from Validator.js which is a library for string validation. | ||
So people who are familiar with Validator.js can easily switch to this library. | ||
|
||
This library is written in pure python and is very easy to use. | ||
It is a simple library that can be used to validate strings, documents, emails, dates, urls, domain names, etc. | ||
|
||
Installation | ||
============ | ||
|
||
To install the library, you can use pip: | ||
|
||
```bash | ||
pip install sanatio | ||
``` | ||
|
||
Usage | ||
===== | ||
|
||
```python | ||
from sanatio import Validator | ||
val = Validator() | ||
# Check if the string is equal to the given value | ||
```python | ||
val.equals("abc", "abc") # True | ||
``` | ||
|
||
|
||
|
||
|
||
|
||
|
||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
python-Levenshtein==0.20.8 | ||
python-Levenshtein==0.25.1 |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
from sanatio.main import Validator | ||
|
||
__all__ = ['Validator'] |
Empty file.
Empty file.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
import setuptools | ||
from glob import glob | ||
|
||
with open("README.md", "r") as fh: | ||
long_description = fh.read() | ||
with open("README.md", "rb") as fh: | ||
long_description = fh.read().decode("utf-8") | ||
|
||
with open("requirements.txt", "r") as fh: | ||
requirements = fh.read().splitlines() | ||
|
||
setuptools.setup( | ||
name="Sanatio", | ||
version="0.0.1", | ||
version="1.0.0", | ||
author="Deepak Raj", | ||
author_email="[email protected]", | ||
description="", | ||
|