Skip to content

Commit 53b9771

Browse files
authored
Merge pull request #85 from fosslight/develop
Analyze the current path if path is null
2 parents 4588e7c + c9e7c6d commit 53b9771

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

src/fosslight_source/cli.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ def main():
4141
_result_log = {}
4242

4343
argv = sys.argv[1:]
44-
path_to_scan = ""
44+
path_to_scan = os.getcwd()
4545
write_json_file = False
4646
output_file_name = ""
4747
print_matched_text = False
@@ -61,6 +61,8 @@ def main():
6161
print_version(_PKG_NAME)
6262
elif opt == "-p":
6363
path_to_scan = arg
64+
if not path_to_scan:
65+
path_to_scan = os.getcwd()
6466
elif opt == "-j":
6567
write_json_file = True
6668
elif opt == "-o":

src/fosslight_source/convert_scancode.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ def get_detected_licenses_from_scancode(scancode_json_file, need_license):
131131

132132
def main():
133133
argv = sys.argv[1:]
134-
path_to_find_json = ""
134+
path_to_find_json = os.getcwd()
135135
output_file_name = ""
136136
print_matched_text = False
137137
format = ""
@@ -145,6 +145,8 @@ def main():
145145
print_version(_PKG_NAME)
146146
elif opt == "-p":
147147
path_to_find_json = arg
148+
if not path_to_find_json:
149+
path_to_find_json = os.getcwd()
148150
elif opt == "-o":
149151
output_file_name = arg
150152
elif opt == "-m":

0 commit comments

Comments
 (0)