Skip to content

Commit fe5e829

Browse files
committed
Merge pull request pre-commit#121 from pre-commit/packages_redux
Packages redux
2 parents 3a38cf4 + a984a02 commit fe5e829

File tree

13 files changed

+23
-18
lines changed

13 files changed

+23
-18
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ test: .venv.touch
1414
tox $(REBUILD_FLAG)
1515

1616

17-
.venv.touch: setup.py requirements.txt requirements-dev.txt
17+
.venv.touch: setup.py requirements-dev.txt
1818
$(eval REBUILD_FLAG := --recreate)
1919
touch .venv.touch
2020

pre_commit/commands/autoupdate.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33

44
import sys
55

6-
from asottile.ordereddict import OrderedDict
76
from asottile.yaml import ordered_dump
87
from asottile.yaml import ordered_load
98
from plumbum import local
@@ -12,6 +11,7 @@
1211
from pre_commit.clientlib.validate_config import CONFIG_JSON_SCHEMA
1312
from pre_commit.clientlib.validate_config import load_config
1413
from pre_commit.jsonschema_extensions import remove_defaults
14+
from pre_commit.ordereddict import OrderedDict
1515
from pre_commit.repository import Repository
1616

1717

pre_commit/five.py

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,10 @@
22

33
"""five: six, redux"""
44
# pylint:disable=invalid-name
5-
PY2 = (str is bytes)
6-
PY3 = (str is not bytes)
5+
PY2 = str is bytes
6+
PY3 = str is not bytes
77

8-
# provide a symettrical `text` type to `bytes`
9-
if PY2:
8+
if PY2: # pragma: no cover (PY2 only)
109
text = unicode # flake8: noqa
11-
else:
10+
else: # pragma: no cover (PY3 only)
1211
text = str

pre_commit/manifest.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
from __future__ import unicode_literals
22

33
import os.path
4-
from asottile.cached_property import cached_property
4+
from cached_property import cached_property
55

66
import pre_commit.constants as C
77
from pre_commit.clientlib.validate_manifest import load_manifest

pre_commit/ordereddict.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
from __future__ import absolute_import
2+
from __future__ import unicode_literals
3+
4+
try:
5+
from collections import OrderedDict # noqa
6+
except ImportError: # pragma: no cover (PY26)
7+
from ordereddict import OrderedDict # noqa

pre_commit/repository.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
from __future__ import unicode_literals
22

3-
from asottile.cached_property import cached_property
4-
from asottile.ordereddict import OrderedDict
3+
from cached_property import cached_property
54

65
from pre_commit.languages.all import languages
76
from pre_commit.manifest import Manifest
7+
from pre_commit.ordereddict import OrderedDict
88
from pre_commit.prefixed_command_runner import PrefixedCommandRunner
99

1010

pre_commit/runner.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
import os
44
import os.path
5-
from asottile.cached_property import cached_property
5+
from cached_property import cached_property
66

77
import pre_commit.constants as C
88
from pre_commit import git

pre_commit/store.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
import os
66
import os.path
77
import tempfile
8-
from asottile.cached_property import cached_property
8+
from cached_property import cached_property
99
from plumbum import local
1010

1111
from pre_commit.prefixed_command_runner import PrefixedCommandRunner

requirements.txt

Lines changed: 0 additions & 1 deletion
This file was deleted.

setup.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,11 @@
3232
},
3333
install_requires=[
3434
'argparse',
35-
'asottile.cached_property',
36-
'asottile.ordereddict',
3735
'asottile.yaml',
36+
'cached-property',
3837
'jsonschema',
3938
'nodeenv>=0.9.4',
39+
'ordereddict',
4040
'plumbum',
4141
'pyyaml',
4242
'simplejson',

0 commit comments

Comments
 (0)