Skip to content

Commit d22e0f8

Browse files
committed
Added lint sessions
1 parent 91d8c2e commit d22e0f8

6 files changed

Lines changed: 30 additions & 0 deletions

File tree

find-project-root/noxfile.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,11 @@ def test_py26(session):
2525
)
2626
clean(session, '--py2')
2727

28+
@session
29+
def lint(session) : session.run('ruff', 'check', '.', *session.posargs)
30+
@session
31+
def lint_fix(session) : session.run('ruff', 'check', '.', '--fix', *session.posargs)
32+
2833
@session
2934
def bump_patch(session, no_push=True):
3035
cmd = ['py', paths.utils.bump, '--patch']

latin-locales/noxfile.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,11 @@ def session(func) : return nox.session(venv_backend='none', name=func.__name__.r
1414
@session
1515
def dev(session) : session.run('pip', 'install', '-e', '.')
1616

17+
@session
18+
def lint(session) : session.run('ruff', 'check', '.', *session.posargs)
19+
@session
20+
def lint_fix(session) : session.run('ruff', 'check', '.', '--fix', *session.posargs)
21+
1722
@session
1823
def bump_patch(session, no_push=True):
1924
cmd = ['py', paths.utils.bump, '--patch']

non-latin-locales/noxfile.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,11 @@ def session(func) : return nox.session(venv_backend='none', name=func.__name__.r
1414
@session
1515
def dev(session) : session.run('pip', 'install', '-e', '.')
1616

17+
@session
18+
def lint(session) : session.run('ruff', 'check', '.', *session.posargs)
19+
@session
20+
def lint_fix(session) : session.run('ruff', 'check', '.', '--fix', *session.posargs)
21+
1722
@session
1823
def bump_patch(session, no_push=True):
1924
cmd = ['py', paths.utils.bump, '--patch']

project-markers/noxfile.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,11 @@ def session(func) : return nox.session(venv_backend='none', name=func.__name__.r
1414
@session
1515
def dev(session) : session.run('pip', 'install', '-e', '.')
1616

17+
@session
18+
def lint(session) : session.run('ruff', 'check', '.', *session.posargs)
19+
@session
20+
def lint_fix(session) : session.run('ruff', 'check', '.', '--fix', *session.posargs)
21+
1722
@session
1823
def bump_patch(session, no_push=True):
1924
cmd = ['py', paths.utils.bump, '--patch']

remove-json-keys/noxfile.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,11 @@ def dev(session) : session.run('pip', 'install', '-e', '.') ; session.run(pkg.di
1616
@session
1717
def debug(session) : session.run('py', '-m', pkg.name, '--debug', *session.posargs, env={ 'PYTHONPATH': 'src' })
1818

19+
@session
20+
def lint(session) : session.run('ruff', 'check', '.', *session.posargs)
21+
@session
22+
def lint_fix(session) : session.run('ruff', 'check', '.', '--fix', *session.posargs)
23+
1924
@session
2025
def bump_patch(session, no_push=True):
2126
cmd = ['py', paths.utils.bump, '--patch']

translate-messages/noxfile.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,11 @@ def dev(session) : session.run('pip', 'install', '-e', '.') ; session.run(pkg.di
1616
@session
1717
def debug(session) : session.run('py', '-m', pkg.name, '--debug', *session.posargs, env={ 'PYTHONPATH': 'src' })
1818

19+
@session
20+
def lint(session) : session.run('ruff', 'check', '.', *session.posargs)
21+
@session
22+
def lint_fix(session) : session.run('ruff', 'check', '--fix', '.', *session.posargs)
23+
1924
@session
2025
def bump_patch(session, no_push=True):
2126
cmd = ['py', paths.utils.bump, '--patch']

0 commit comments

Comments
 (0)