Skip to content

Commit 73f3fc4

Browse files
authored
Merge pull request #55 from ajinabraham/3.1.6
Expose multiprocessing to cli args
2 parents b8b4048 + 272cdc7 commit 73f3fc4

File tree

3 files changed

+9
-2
lines changed

3 files changed

+9
-2
lines changed

libsast/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
__title__ = 'libsast'
1313
__authors__ = 'Ajin Abraham'
1414
__copyright__ = f'Copyright {year} Ajin Abraham, opensecurity.in'
15-
__version__ = '3.1.5'
15+
__version__ = '3.1.6'
1616
__version_info__ = tuple(int(i) for i in __version__.split('.'))
1717
__all__ = [
1818
'Scanner',

libsast/__main__.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,12 @@ def main():
7878
help='No of CPU cores to use. Use all cores by default',
7979
type=int,
8080
required=False)
81+
parser.add_argument('-mp', '--multiprocessing',
82+
help=('Multiprocessing strategy to use.'
83+
' Options: default, thread, billiard'),
84+
default='default',
85+
type=str,
86+
required=False)
8187
parser.add_argument('-v', '--version',
8288
help='Show libsast version',
8389
required=False,
@@ -94,6 +100,7 @@ def main():
94100
'ignore_paths': args.ignore_paths,
95101
'show_progress': args.show_progress,
96102
'cpu_core': args.cpu_core,
103+
'multiprocessing': args.multiprocessing,
97104
}
98105
result = Scanner(options, args.path).scan()
99106
output(args.output, result)

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "libsast"
3-
version = "3.1.5"
3+
version = "3.1.6"
44
description = "A generic SAST library built on top of semgrep and regex"
55
keywords = ["libsast", "SAST", "Python SAST", "SAST API", "Regex SAST", "Pattern Matcher"]
66
authors = ["Ajin Abraham <ajin@opensecurity.in>"]

0 commit comments

Comments
 (0)