Skip to content

Commit 5b577bd

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent e2158d6 commit 5b577bd

File tree

2 files changed

+11
-20
lines changed

2 files changed

+11
-20
lines changed

src/incremental/update.py

Lines changed: 9 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -48,31 +48,22 @@ def _run(
4848
path = _findPath(_getcwd(), package)
4949

5050
if (
51-
(newversion
52-
and patch)
53-
or (newversion
54-
and dev)
55-
or (newversion
56-
and rc)
57-
or (newversion
58-
and post)
51+
(newversion and patch)
52+
or (newversion and dev)
53+
or (newversion and rc)
54+
or (newversion and post)
5955
):
6056
raise ValueError("Only give --newversion")
6157

6258
if (dev and patch) or (dev and rc) or (dev and post):
6359
raise ValueError("Only give --dev")
6460

6561
if (
66-
(create
67-
and dev)
68-
or (create
69-
and patch)
70-
or (create
71-
and rc)
72-
or (create
73-
and post)
74-
or (create
75-
and newversion)
62+
(create and dev)
63+
or (create and patch)
64+
or (create and rc)
65+
or (create and post)
66+
or (create and newversion)
7667
):
7768
raise ValueError("Only give --create")
7869

tests/test_examples.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@
1010
from subprocess import run
1111
from tempfile import TemporaryDirectory
1212

13+
from build import BuildBackendException, ProjectBuilder
14+
from build.env import DefaultIsolatedEnv
1315
from twisted.python.filepath import FilePath
1416
from twisted.trial.unittest import TestCase
1517

16-
from build import BuildBackendException, ProjectBuilder
17-
from build.env import DefaultIsolatedEnv
1818
from incremental import Version
1919

2020
TEST_DIR = FilePath(os.path.abspath(os.path.dirname(__file__)))

0 commit comments

Comments
 (0)