-
Notifications
You must be signed in to change notification settings - Fork 0
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 #1 from davidpeckham/mkdocs
Added MkDocs documentation
- Loading branch information
Showing
21 changed files
with
402 additions
and
259 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
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,5 @@ | ||
# https://linkchecker.github.io/linkchecker/man/linkcheckerrc.html | ||
[filtering] | ||
ignore= | ||
|
||
[AnchorCheck] |
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,20 @@ | ||
# Changelog | ||
|
||
## v0.2.0 (2024-02-03) | ||
|
||
[GitHub release](https://github.com/davidpeckham/vin/releases/tag/v0.2.0) | ||
|
||
### New Features | ||
|
||
* Validate VIN length, characters, and check digit, with the option to correct the check digit. | ||
* Decode the manufacturer and model year from a VIN | ||
* Documentation | ||
|
||
### Fixes | ||
|
||
* Updated annotations for `VIN.vds` and `VIN.vis` to show that they don't return None | ||
* Annotated `VIN.model_year` to show that it returns int, and removed the else condition that allowed it to return None | ||
* Inlined `VIN.is_vin_character` in the default constructor | ||
* Converted property `VIN.check_digit` to class method `VIN.calculate_check_digit` | ||
* Converted ``constants.VIN_CHARACTERS`` from list to string | ||
* Renamed GitHub workflows as .yml (from .yaml) |
This file was deleted.
Oops, something went wrong.
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 was deleted.
Oops, something went wrong.
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,6 @@ | ||
# API | ||
|
||
::: vin.VIN | ||
options: | ||
members_order: source | ||
filters: ['!_vin', '!__repr__', '!__str__'] |
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,9 @@ | ||
# Help | ||
|
||
## :material-api: API Documentation | ||
|
||
The [API documentation](api.md) is the best way to learn what VIN can do for you. | ||
|
||
## :simple-github: GitHub Issues | ||
|
||
Use [GitHub issues](https://github.com/davidpeckham/vin/issues) to ask questions, report issues, and suggest changes. |
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,5 @@ | ||
import shutil | ||
|
||
|
||
def copy_history(*args, **kwargs): | ||
shutil.copy("CHANGELOG.md", "docs/changelog.md") |
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,74 @@ | ||
# VIN | ||
|
||
[![PyPI - Version](https://img.shields.io/pypi/v/vin.svg)](https://pypi.org/project/vin) | ||
[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/vin.svg)](https://pypi.org/project/vin) | ||
[![license](https://img.shields.io/github/license/davidpeckham/vin.svg)](https://github.com/davidpeckham/vin/blob/main/LICENSE) | ||
|
||
|
||
----- | ||
|
||
VIN validates Vehicle Identification Numbers and decodes the vehicle's manufacturer, make, model, and model year. | ||
|
||
>>> from vin import VIN | ||
|
||
>>> vin("5FNYF5H59HB011946").manufacturer | ||
Honda | ||
|
||
>>> vin("YT9NN1U14KA007175").manufacturer | ||
Koenigsegg | ||
|
||
>>> vin("5FNYF5H59HB011946").model_year | ||
2017 | ||
|
||
## Why use VIN? | ||
|
||
- **Accurate** — Vehicle information is provided by the National Highway Traffic Safety Administration. | ||
- **Fast** — Vehicle data is included and periodically updated, so validation and decoding are fast. | ||
|
||
## Vehicle Identification Number | ||
|
||
A ``VIN`` is a unique 17-character Vehicle Identification Number. | ||
|
||
* Assigned by vehicle manufacturers | ||
* Uniquely identifies vehicles manufactured for sale or use in the United States since 1980 | ||
* Governed by the U.S. National Highway Traffic Safety Administration (NHTSA) | ||
|
||
The structure of the VIN is: | ||
|
||
model year | ||
| | ||
WMI check digit | plant | ||
|-----| | | | |--- serial ----| | ||
Position 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | ||
|-----------| |---------------------| | ||
VDS VIS | ||
|
||
The World Manufacturer Identifier (WMI) holds the country, region, and | ||
name of the vehicle manufacturer. Mass-market manufacturers are assigned | ||
a three-character WMI. Specialized manufacturers are assigned a six- | ||
character WMI (positions 1-3 and 12-14) | ||
|
||
The Vehicle Description Section (VDS) is defined by manufacturers to | ||
identify the vehicle make, model, body type, engine type, restraints, | ||
and the weight class (for trucks and multi-purpose vehicles). | ||
|
||
The Vehicle Identification Section (VIS) identifies the model year, | ||
plant where the vehicle was made, and the vehicle's serial number. | ||
|
||
For more information, see the [VIN specification](https://www.ecfr.gov/current/title-49/subtitle-B/chapter-V/part-565). | ||
|
||
Installation | ||
------------ | ||
|
||
Use ``pip`` to install the library: | ||
|
||
$ pip install vin | ||
|
||
## Vehicle Data | ||
|
||
Vehicle data is provided by the U.S. National Highway Traffic Safety Administration (NHTSA) [Product Information Catalog and Vehicle Listing (vPIC)](https://vpic.nhtsa.dot.gov). | ||
|
||
## License | ||
|
||
VIN is distributed under the terms of the [MIT](https://spdx.org/licenses/MIT.html) license. | ||
|
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.