Sha256: 1be2a2a0479f112347a3d734b596e3ad72f197b30efa4294b59d0ed01eaff812

Contents?: true

Size: 644 Bytes

Versions: 1

Compression:

Stored size: 644 Bytes

Contents

#!/usr/bin/env bash

set -e
DIR=$(cd `dirname $0` && pwd)
ROOT_DIR="${DIR}/.."

scan_for () {
  SEARCH_STRING=$1
  SCAN_TARGETS=( "docs" "lib/hellosign-ruby-sdk/api" "lib/hellosign-ruby-sdk/models" "README.md" )

  printf "Scanning for '${SEARCH_STRING}': "

  set +e
  for i in "${SCAN_TARGETS[@]}"
  do
    grep -ilr "${SEARCH_STRING}" "${ROOT_DIR}/${i}"
    if [ $? -eq 0 ]; then
      printf "Error: ${SEARCH_STRING} found in ${i}\n"
      exit 1
    fi
  done

  printf "'${SEARCH_STRING}' not found\n"
  set -e
}

scan_for "allof"
scan_for "oneof"
scan_for "REPLACE_ME_WITH_DESCRIPTION"
scan_for "REPLACE_ME_WITH_EXAMPLE_FOR"
printf "\n"

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
hellosign-ruby-sdk-6.0.0.pre.beta bin/scan_for