Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
6 changes: 3 additions & 3 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install networkx lxml
python -m pip install --upgrade pip pytest
pip install -e .
- name: Tests
run: python ./tests/testthat.py
run: pytest
13 changes: 8 additions & 5 deletions .github/workflows/transform.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,21 @@
name: Transform

on:
push:
on:
push:
branches:
- main
paths:
- 'data/**'
- 'src/openstemmata/data/**'

workflow_dispatch: #Allows for manual triggering

jobs:
build:
runs-on: ubuntu-latest
env:
GITHUB_TOKEN: ${{ secrets.TOKEN_PUSH }}
PACKAGE_PATH: src/openstemmata

steps:
- name: checkout repo content
uses: actions/checkout@v2
Expand All @@ -27,10 +30,10 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install networkx lxml
pip install -r requirements.txt
- name: Convert files
run: |
for file in ./data/*/*/* ; do
for file in ./${{ PACKAGE_PATH }}/data/*/*/* ; do
if [ "${file: -9}" == "stemma.gv" ] || [ "${file: -12}" == "metadata.txt" ] ;
then python ./tests/transformation.py ${file} ;
fi
Expand Down
6 changes: 5 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,6 @@
.Rhistory
*pycache*
*pycache*
dist/
OpenStemmata_database.egg-info
.coverage
.idea
2 changes: 1 addition & 1 deletion CITATION.cff
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@

cff-version: 1.2.0
message: "If you use this collection, please cite it as below (in adddition to references to the sources)."
message: "If you use this collection, please cite it as below (in addition to references to the sources)."
authors:
- family-names: "Camps"
given-names: "Jean-Baptiste"
Expand Down
3 changes: 3 additions & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
graft src
recursive-exclude __pycache__ *.py[cod]
exclude tests/**
3 changes: 3 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[build-system]
requires = ["setuptools", "wheel"]
build-backend = "setuptools.build_meta"
2 changes: 2 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
networkx==3.3
lxml==5.2.2
82 changes: 82 additions & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
[metadata]
name = openstemmata
version = 0.1.0

author =
author_email =
url='https://github.com/OpenStemmata/database',

description = An open source collection of historical text genealogies, in forms of tree-like graphs (stemma) for a variety of languages.
long_description = file: README.md
long_description_content_type = text/markdown

keywords =
manuscript
stemmatology
license = CC-BY-SA-4.0 license
license_files = LICENSE

platforms = any
classifiers =
Development Stats ::
Intended Audience :: Science/Research
Operating System :: OS Independent
License :: Other/Proprietary License (CC-BY License)
Programming Language :: Python :: 3
Programming Language :: Python :: 3.8
Programming Language :: Python :: 3.9
Programming Language :: Python :: 3.10
Programming Language :: Python :: 3.11
Programming Language :: Python :: 3.12

[options]
zip_safe = False
packages = find:
package_dir =
=src
install_requires =
networkx
lxml
include_package_data = True


;include_dirs=[]

[options.packages.find]
where = src
exclude =
test*

[options.package_data]
opentstemmata =
data/*
examples/*
schema/*

;[testimports]
;deps =
; pytest
; pytest-cov
;
;[test-env]
;deps =
; {[testimports]deps}
;commands =
; pytest {posargs}
;
;[options.extras_require] # in setup.cfg
;test =
; pytest
; pytest-cov
;
;[tool:pytest]
;addopts = --cov
;testpaths =
; tests
;
;[coverage:run]
;source=openstemmata_database
;
;[coverage:report]
;show_missing = True

3 changes: 3 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
from setuptools import setup

setup()
3 changes: 3 additions & 0 deletions src/openstemmata/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import os

PACK_DIR = os.path.abspath(os.path.dirname(__file__))
Loading