testing/vint: new aport

Closes GH-7859
This commit is contained in:
Keith Maxwell 2019-05-13 10:15:58 +01:00 committed by Kevin Daudt
parent 8d2e670c39
commit 4c33316a57
3 changed files with 58 additions and 0 deletions

View File

@ -0,0 +1,8 @@
--- a/bin/vint
+++ b/bin/vint
@@ -1,4 +1,4 @@
-#!/usr/bin/env python
+#!/usr/bin/env python3
import sys
from pathlib import Path

View File

@ -0,0 +1,18 @@
--- a/requirements.txt
+++ b/requirements.txt
@@ -1,3 +1,3 @@
-PyYAML ~= 3.11
+PyYAML
ansicolor ~= 0.2.4
chardet >= 2.3.0
--- a/vint/linting/config/config_file_source.py
+++ b/vint/linting/config/config_file_source.py
@@ -10,7 +10,7 @@
config_file_path = self.get_file_path(env)
with config_file_path.open() as file_obj:
- self._config_dict = self.convert_config_dict(yaml.load(file_obj))
+ self._config_dict = self.convert_config_dict(yaml.full_load(file_obj))
def convert_config_dict(self, yaml_dict):

32
testing/vint/APKBUILD Normal file
View File

@ -0,0 +1,32 @@
# Contributor: Keith Maxwell <keith.maxwell@gmail.com>
# Maintainer: Keith Maxwell <keith.maxwell@gmail.com>
pkgname=vint
pkgver=0.3.19
pkgrel=0
pkgdesc="Fast and Highly Extensible Vim script Language Lint"
url="https://github.com/Kuniwak/vint"
arch="noarch"
license="MIT"
depends="python3 py3-yaml py3-chardet py3-ansicolor py3-setuptools"
checkdepends="py3-pytest py3-pytest-cov py3-coverage"
# no tests in artifact on PyPI
source="$pkgname-$pkgver.tar.gz::https://github.com/Kuniwak/$pkgname/archive/v$pkgver.tar.gz
01-python3-shebang.patch
02-latest-py3-yaml.patch
"
build() {
python3 setup.py build
}
check() {
python3 -m pytest
}
package() {
python3 setup.py install --prefix=/usr --root="$pkgdir"
}
sha512sums="b9024ed1cd8a18a916798e691ba0db31985034b2420e33c094459a48254c7c8f6fe89a1a64858a67ff95b0b48e67a780cf975940646af2685d2b95640e8121f9 vint-0.3.19.tar.gz
e777c74ffc16964848f22f051281a284fa05774bd7be9417ea5ad033ea9bc264687df10151e08bf5d319aa7168481e5dd8e3366a942af4fe739ef64511268fa4 01-python3-shebang.patch
c167bd9a1a455ea7d6344eb08448f97cadafec7886cabee42b032b8daf20c2ff85e0c5b87cd72b747213859b6d31d2b33d0fa7147f83facd05fe50ac9d35f971 02-latest-py3-yaml.patch"