You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
1. Create the `artifacts` directory for the code to be analyzed (without `cd` afterwards)
33
+
1. Create the `artifacts` directory for the code to be analyzed (without `cd` afterwards).
34
34
35
35
```shell
36
36
mkdir artifacts
37
37
```
38
38
39
-
1. Move the artifacts (Java jar or Typescript analysis json files) you want to analyze into the `artifacts` directory
39
+
1. Move the artifacts (e.g. Java jars json files) you want to analyze into the `artifacts` directory.
40
+
41
+
1. Optionally, create a subdirectory `typescript` inside the `artifacts` directory and move the Typescript analysis json files you want to analyze into it.
40
42
41
43
1. Optionally, create a `source` directory and clone the corresponding source code into it to also gather git log data.
42
44
@@ -46,9 +48,9 @@ Please read through the [Prerequisites](./README.md#hammer_and_wrench-prerequisi
Copy file name to clipboardExpand all lines: README.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -93,7 +93,7 @@ This could be as simple as running the following command in your Typescript proj
93
93
94
94
- It is recommended to put the cloned source code repository into a directory called `source` within the analysis workspace so that it will also be picked up to import git log data.
95
95
96
-
- Copy the resulting json file (e.g. `.reports/jqa/ts-output.json`) into the `artifacts` directory for your analysis work directory. Custom subdirectories within `artifacts` are also supported.
96
+
- Copy the resulting json file (e.g. `.reports/jqa/ts-output.json`) into the `artifacts/typescript` directory for your analysis work directory. Create the directory, if it doesn't exists. Custom subdirectories within `artifacts/typescript` are also supported.
ARTIFACTS_DIRECTORY=${ARTIFACTS_DIRECTORY:-"artifacts"}# Working directory containing the artifacts to be analyzed
13
+
TYPESCRIPT_ARTIFACTS_DIRECTORY=${TYPESCRIPT_ARTIFACTS_DIRECTORY:-"typescript"}# Subdirectory of "artifacts" containing the typescript analysis result json files for import
11
14
12
15
# Check if the artifacts directory exists
13
16
if [ !-d"./${ARTIFACTS_DIRECTORY}" ] ;then
14
-
echo""# The artifact directory doesn't exist. There is no file at all.
15
-
exit 0
17
+
echo"findTypescriptDataFiles: No files to analyze because of missing directory ${ARTIFACTS_DIRECTORY}">&2
18
+
echo""# The artifact directory doesn't exist. There is no file to analyze.
19
+
return 0
16
20
fi
17
21
18
-
find "./${ARTIFACTS_DIRECTORY}" -type f -name 'ts-*.json' -exec echo {} \;| sed 's/^/typescript:project::/'| tr '\n'''
22
+
# Check if there is a typescript directory within the artifacts directory
23
+
if [ !-d"./${ARTIFACTS_DIRECTORY}/${TYPESCRIPT_ARTIFACTS_DIRECTORY}" ] ;then
24
+
echo"findTypescriptDataFiles: No files to analyze because of missing directory ${ARTIFACTS_DIRECTORY}/${TYPESCRIPT_ARTIFACTS_DIRECTORY}">&2
25
+
echo""# The directory artifact/typescript doesn't exist. There is no file to analyze.
26
+
return 0
27
+
fi
28
+
29
+
find "./${ARTIFACTS_DIRECTORY}/${TYPESCRIPT_ARTIFACTS_DIRECTORY}" -type f -name '*.json' -exec echo {} \;| sed 's/^/typescript:project::/'| tr '\n'''
0 commit comments