AnalogTapeModel

Physical modelling signal processing for analog tape recording
Log | Files | Refs | Submodules | README | LICENSE

validate.sh (1656B)


      1 #!/bin/bash
      2 
      3 # install functions
      4 install_pluginval_linux()
      5 {
      6     curl -L "https://github.com/Tracktion/pluginval/releases/download/latest_release/pluginval_Linux.zip" -o pluginval.zip
      7     unzip pluginval > /dev/null
      8     echo "./pluginval"
      9 }
     10 
     11 install_pluginval_mac()
     12 {
     13     curl -L "https://github.com/Tracktion/pluginval/releases/download/latest_release/pluginval_macOS.zip" -o pluginval.zip
     14     unzip pluginval > /dev/null
     15     echo "pluginval.app/Contents/MacOS/pluginval"
     16 }
     17 
     18 install_pluginval_win()
     19 {
     20     powershell -Command "[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; Invoke-WebRequest https://github.com/Tracktion/pluginval/releases/download/latest_release/pluginval_Windows.zip -OutFile pluginval.zip"
     21     powershell -Command "Expand-Archive pluginval.zip -DestinationPath ."
     22     echo "./pluginval.exe"
     23 }
     24 
     25 # install
     26 if [[ "$OSTYPE" == "linux-gnu"* ]]; then
     27     pluginval=$(install_pluginval_linux)
     28     plugin="Plugin/build/CHOWTapeModel_artefacts/Release/VST3/CHOWTapeModel.vst3"
     29 elif [[ "$OSTYPE" == "darwin"* ]]; then
     30     pluginval=$(install_pluginval_mac)
     31     plugin="Plugin/build/CHOWTapeModel_artefacts/Release/VST3/CHOWTapeModel.vst3"
     32 else
     33     pluginval=$(install_pluginval_win)
     34     plugin="Plugin/build/CHOWTapeModel_artefacts/Release/VST3/CHOWTapeModel.vst3"
     35 fi
     36 
     37 echo "Pluginval installed at ${pluginval}"
     38 echo "Validating ${plugin}"
     39 
     40 n_tries=0
     41 result=1
     42 until [ "$n_tries" -ge 4 ] || [ "$result" -eq 0 ]
     43 do
     44    $pluginval --strictness-level 8 --timeout-ms 90000 --validate-in-process --skip-gui-tests --validate $plugin
     45    result=$?
     46    n_tries=$((n_tries+1))
     47 done
     48 
     49 # clean up
     50 rm -Rf pluginval*
     51 exit $result