-
Notifications
You must be signed in to change notification settings - Fork 43
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 #281 from allenai/modernization
project modernization
- Loading branch information
Showing
8 changed files
with
116 additions
and
147 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,27 @@ | ||
name: Upload Python Package | ||
|
||
on: | ||
release: | ||
types: [created] | ||
|
||
jobs: | ||
pypi: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v2 | ||
with: | ||
python-version: '3.x' | ||
- name: install-deps | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install setuptools wheel twine | ||
- name: build | ||
run: | | ||
python -m build | ||
- name: upload | ||
env: | ||
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }} | ||
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }} | ||
run: | | ||
twine upload dist/* |
This file was deleted.
Oops, something went wrong.
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,43 @@ | ||
name: test | ||
|
||
on: | ||
push: {branches: [master]} # pushes to master | ||
pull_request: {} # all PRs | ||
|
||
jobs: | ||
pytest: | ||
strategy: | ||
matrix: | ||
python-version: ['3.8', '3.11'] | ||
os: ['ubuntu-latest', 'windows-latest', 'macOs-13'] | ||
|
||
runs-on: ${{ matrix.os }} | ||
steps: | ||
|
||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Install Dependencies | ||
run: | | ||
pip install --upgrade -r requirements.txt -r requirements-test.txt | ||
pip install -e . | ||
- name: Unit Test | ||
if: matrix.os == 'ubuntu-latest' || matrix.os == 'macOs-latest' | ||
run: | | ||
pip install pytest | ||
pytest test/util.py test/metadata.py test/integration/dummy.py test/integration/vaswani.py test/formats/ test/test_defaulttext.py | ||
- name: Unit Test (Windows) | ||
if: matrix.os == 'windows-latest' | ||
shell: cmd | ||
run: | | ||
pip install pytest | ||
pytest test\util.py test\metadata.py test\integration\dummy.py test\integration\vaswani.py test\formats\ test\test_defaulttext.py | ||
env: | ||
PATH: 'C:/Program Files/zlib/bin/' |
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 |
---|---|---|
@@ -1,5 +1,3 @@ | ||
include ir_datasets/docs/*.yaml | ||
include ir_datasets/docs/*.bib | ||
include ir_datasets/etc/*.json | ||
include requirements.txt | ||
include LICENSE | ||
recursive-include ir_datasets *.yaml | ||
recursive-include ir_datasets *.bib | ||
recursive-include ir_datasets *.json |
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,43 @@ | ||
[build-system] | ||
requires = ["setuptools>=42", "wheel"] | ||
build-backend = "setuptools.build_meta" | ||
|
||
[project] | ||
name = "ir_datasets" | ||
description = "provides a common interface to many IR ad-hoc ranking benchmarks, training datasets, etc." | ||
readme = "README.md" | ||
authors = [ | ||
{name = "Sean MacAvaney", email = "[email protected]"}, | ||
] | ||
maintainers = [ | ||
{name = "Sean MacAvaney", email = "[email protected]"}, | ||
] | ||
requires-python = ">=3.8" | ||
classifiers = [ | ||
"Programming Language :: Python", | ||
"Operating System :: OS Independent", | ||
"Topic :: Text Processing", | ||
"Topic :: Text Processing :: Indexing", | ||
"License :: OSI Approved :: MIT License", | ||
] | ||
dynamic = ["version", "dependencies"] | ||
|
||
[tool.setuptools] | ||
include-package-data = true | ||
|
||
[tool.setuptools.packages.find] | ||
exclude = ["test"] | ||
|
||
[tool.setuptools.dynamic] | ||
version = {attr = "ir_datasets.__version__"} | ||
dependencies = {file = ["requirements.txt"]} | ||
|
||
[project.urls] | ||
"Homepage" = "https://ir-datasets.com/" | ||
"Documentation" = "https://project.readthedocs.io/" | ||
"Source" = "https://github.com/allenai/ir_datasets" | ||
"Issues" = "https://github.com/allenai/ir_datasets/issues" | ||
"Bug Tracker" = "https://github.com/allenai/ir_datasets/issues" | ||
|
||
[project.scripts] | ||
ir_datasets = "ir_datasets:main_cli" |