2021-07-30 15:29:12 +05:30
|
|
|
#!/bin/bash
|
|
|
|
|
|
2021-12-16 02:17:29 -06:00
|
|
|
# reading os type from arguments
|
|
|
|
|
CURRENT_OS=$1
|
|
|
|
|
|
2023-03-06 01:57:55 +05:30
|
|
|
if [ "${CURRENT_OS}" == "windows-latest-8-cores" ];then
|
2021-12-16 02:17:29 -06:00
|
|
|
extension=.exe
|
|
|
|
|
fi
|
|
|
|
|
|
2021-12-14 18:13:53 +02:00
|
|
|
echo "::group::Building functional-test binary"
|
2021-12-16 02:17:29 -06:00
|
|
|
go build -o functional-test$extension
|
2021-12-14 18:13:53 +02:00
|
|
|
echo "::endgroup::"
|
2021-08-02 11:40:44 +05:30
|
|
|
|
2021-12-14 18:13:53 +02:00
|
|
|
echo "::group::Building Nuclei binary from current branch"
|
2021-12-16 02:17:29 -06:00
|
|
|
go build -o nuclei_dev$extension ../nuclei
|
2021-12-14 18:13:53 +02:00
|
|
|
echo "::endgroup::"
|
2021-08-02 11:40:44 +05:30
|
|
|
|
2022-03-03 19:10:03 +05:30
|
|
|
echo "::group::Installing nuclei templates"
|
2022-03-03 19:51:16 +05:30
|
|
|
./nuclei_dev$extension -update-templates
|
2022-03-03 19:10:03 +05:30
|
|
|
echo "::endgroup::"
|
|
|
|
|
|
2021-12-16 02:17:29 -06:00
|
|
|
echo "::group::Building latest release of nuclei"
|
|
|
|
|
go build -o nuclei$extension -v github.com/projectdiscovery/nuclei/v2/cmd/nuclei
|
2021-12-14 18:13:53 +02:00
|
|
|
echo "::endgroup::"
|
2021-08-02 11:40:44 +05:30
|
|
|
|
|
|
|
|
echo 'Starting Nuclei functional test'
|
2021-12-16 02:17:29 -06:00
|
|
|
./functional-test$extension -main ./nuclei$extension -dev ./nuclei_dev$extension -testcases testcases.txt
|