Skip to content

Commit

Permalink
Merge pull request #23 from coolbho3k/develop
Browse files Browse the repository at this point in the history
Version 1.1.1
  • Loading branch information
tristanlatr authored Jun 6, 2020
2 parents 00d1480 + 7887696 commit 97cda2a
Show file tree
Hide file tree
Showing 9 changed files with 33,641 additions and 19,546 deletions.
35 changes: 35 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# This workflow will install Python dependencies, run tests and lint with a variety of Python versions
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions

name: test
on: pull_request
jobs:
test:
name: ${{ matrix.os }} Python ${{ matrix.python-version }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [windows-latest, ubuntu-latest, macos-latest]
python-version: ['2.7','3.5','3.6','3.7','3.8']
fail-fast: false
steps:
- uses: actions/checkout@v1
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v1
with:
python-version: ${{ matrix.python-version }}
- name: Run tests
run: |
python -m pip install --upgrade pip
pip install pylint codecov pytest pytest-cov
pytest --cov=./ --cov-report=xml
# TODO : Need to setup secrets.CODECOV_TOKEN on github repository
# - name: Upload code coverage
# uses: codecov/codecov-action@v1
# with:
# token: ${{ secrets.CODECOV_TOKEN }}
# file: ./coverage.xml
# name: manuf-code-coverage
# yml: ./codecov.yml
# fail_ci_if_error: true
13 changes: 0 additions & 13 deletions .travis.yml

This file was deleted.

45 changes: 34 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
manuf.py
manuf
===

[![Build Status](https://travis-ci.org/coolbho3k/manuf.svg?branch=master)](https://travis-ci.org/coolbho3k/manuf)
[![Build Status](https://github.com/coolbho3k/manuf/workflows/test/badge.svg)](https://github.com/coolbho3k/manuf/actions)
[![Build Status](https://badge.fury.io/py/manuf.svg)](https://pypi.org/project/manuf/)

Parser library for Wireshark's OUI database.
---
Expand All @@ -17,10 +18,23 @@ See [Wireshark's OUI lookup tool](https://www.wireshark.org/tools/oui-lookup.htm

Written by Michael Huang (coolbho3k).

Install
---

#### With PyPi

pip install manuf

#### Or Manually

git clone https://github.com/coolbho3k/manuf
cd manuf
python setup.py install

Usage
---

As a library:
#### As a library:

>>> from manuf import manuf
>>> p = manuf.MacParser(update=True)
Expand All @@ -31,12 +45,7 @@ As a library:
>>> p.get_comment('BC:EE:7B:00:00:00')
'ASUSTek COMPUTER INC.'

On the command line:

$ python -m manuf BC:EE:7B:00:00:00
Vendor(manuf='AsustekC', comment='ASUSTek COMPUTER INC.')

Alternatively, if the library has been installed i.e. using pip
#### As a command line:

$ manuf BC:EE:7B:00:00:00
Vendor(manuf='AsustekC', comment='ASUSTek COMPUTER INC.')
Expand All @@ -57,7 +66,16 @@ modify this, or do not have permissions to do so, you must specify a custom manu
$ manuf --update --manuf ~/manuf BC:EE:7B:00:00:00
Vendor(manuf='AsustekC', comment='ASUSTek COMPUTER INC.')

Advantages
Alternatively you can call the program with:

python -m manuf
or by executung the `manuf.py` script directly

```bash
./manuf/manuf.py # From the install folder
```

Features and advantages of manuf
---

Note: the examples use the manuf file provided in the first commit, 9a180b5.
Expand Down Expand Up @@ -172,4 +190,9 @@ The database there is updated about once a week, so you may want to grab the
latest version to use instead of using the one provided here by using the
--update flag on the command line:

python manuf.py --update
manuf --update

Run tests
---

python -m unittest manuf.test.test_manuf
Loading

0 comments on commit 97cda2a

Please sign in to comment.