Add helper scripts used to test mutiple github repos. (#52)
diff --git a/scancode/utils/clone_all.sh b/scancode/utils/clone_all.sh
new file mode 100755
index 0000000..cc75383
--- /dev/null
+++ b/scancode/utils/clone_all.sh
@@ -0,0 +1,31 @@
+#!/bin/bash
+# Licensed to the Apache Software Foundation (ASF) under one or more contributor
+# license agreements; and to You under the Apache License, Version 2.0.
+
+USAGE=$"USAGE: clone_all <repo-list.txt> <ORIGIN> <UPSTREAM>\n"
+
+if [ $1 ]
+then
+ if [ $2 ]
+ then
+ if [ $3 ]
+ then
+ while read fn; do
+ printf "cloning:" $fn
+ source ./repo_clone.sh $fn $2 $3
+ done < $1
+ else
+ printf "ERROR: Did not add Github fork name for UPSTREAM. Did not add REMOTE\n"
+ printf "$USAGE"
+ exit 3
+ fi
+ else
+ printf "ERROR: Argument not present: GitHub Organization Name\n"
+ printf "$USAGE"
+ exit 2
+ fi
+else
+ echo "ERROR: Argument not present: Repository Text listing (.txt)\n"
+ printf "$USAGE"
+ exit 1
+fi
diff --git a/scancode/utils/openwhisk-repos.txt b/scancode/utils/openwhisk-repos.txt
new file mode 100644
index 0000000..3076ff5
--- /dev/null
+++ b/scancode/utils/openwhisk-repos.txt
@@ -0,0 +1,49 @@
+incubator-openwhisk
+incubator-openwhisk-apigateway
+incubator-openwhisk-catalog
+incubator-openwhisk-cli
+incubator-openwhisk-client-go
+incubator-openwhisk-client-js
+incubator-openwhisk-client-python
+incubator-openwhisk-client-swift
+incubator-openwhisk-composer
+incubator-openwhisk-debugger
+incubator-openwhisk-deploy-kube
+incubator-openwhisk-deploy-mesos
+incubator-openwhisk-deploy-openshift
+incubator-openwhisk-devtools
+incubator-openwhisk-external-resources
+incubator-openwhisk-GitHubSlackBot
+incubator-openwhisk-package-alarms
+incubator-openwhisk-package-cloudant
+incubator-openwhisk-package-deploy
+incubator-openwhisk-package-jira
+incubator-openwhisk-package-kafka
+incubator-openwhisk-package-pushnotifications
+incubator-openwhisk-package-rss
+incubator-openwhisk-package-template
+incubator-openwhisk-playground
+incubator-openwhisk-podspecs
+incubator-openwhisk-release
+incubator-openwhisk-runtime-docker
+incubator-openwhisk-runtime-ballerina
+incubator-openwhisk-runtime-dotnet
+incubator-openwhisk-runtime-go
+incubator-openwhisk-runtime-java
+incubator-openwhisk-runtime-nodejs
+incubator-openwhisk-runtime-php
+incubator-openwhisk-runtime-python
+incubator-openwhisk-runtime-ruby
+incubator-openwhisk-runtime-swift
+incubator-openwhisk-sample-matos
+incubator-openwhisk-sample-slackbot
+incubator-openwhisk-selfserve-test
+incubator-openwhisk-slackinvite
+incubator-openwhisk-test
+incubator-openwhisk-tutorial
+incubator-openwhisk-utilities
+incubator-openwhisk-vscode
+incubator-openwhisk-website
+incubator-openwhisk-workshop
+incubator-openwhisk-wskdeploy
+incubator-openwhisk-xcode
diff --git a/scancode/utils/release-repos.txt b/scancode/utils/release-repos.txt
new file mode 100644
index 0000000..19ffd20
--- /dev/null
+++ b/scancode/utils/release-repos.txt
@@ -0,0 +1,13 @@
+incubator-openwhisk
+incubator-openwhisk-apigateway
+incubator-openwhisk-catalog
+incubator-openwhisk-cli
+incubator-openwhisk-client-go
+incubator-openwhisk-deploy-kube
+incubator-openwhisk-runtime-docker
+incubator-openwhisk-runtime-java
+incubator-openwhisk-runtime-nodejs
+incubator-openwhisk-runtime-php
+incubator-openwhisk-runtime-python
+incubator-openwhisk-runtime-swift
+incubator-openwhisk-wskdeploy
diff --git a/scancode/utils/repo_clone.sh b/scancode/utils/repo_clone.sh
new file mode 100755
index 0000000..8cd8873
--- /dev/null
+++ b/scancode/utils/repo_clone.sh
@@ -0,0 +1,47 @@
+#!/bin/bash
+# Licensed to the Apache Software Foundation (ASF) under one or more contributor
+# license agreements; and to You under the Apache License, Version 2.0.
+
+USAGE="repo_clone <repo. name> <ORIGIN> <UPSTREAM>"
+
+if [ $1 ]
+then
+ : # $1 was given
+ REPO=$1
+
+ if [ $2 ]
+ then
+ :
+ OWNER=$2
+ else
+ echo "ERROR: Did not add Github fork name for ORIGIN."
+ echo $USAGE
+ exit 2
+ fi
+
+ echo "REPO=[$1]"
+ echo "OWNER=[$2]"
+
+ echo "Info: Cloning: git@github.com:$OWNER/$REPO ..."
+ git clone git@github.com:$OWNER/$REPO
+ echo "Info: Remotes: git remote"
+ git remote
+
+ if [ $3 ]
+ then
+ cd $REPO
+ echo "Info: Adding UPSTREAM remote: 'git remote add upstream git@github.com:$3/$REPO' ..."
+ git remote add upstream git@github.com:$3/$REPO
+ echo "Info: Fetching remotes: 'git fetch --all' ..."
+ git fetch --all
+ echo "Info: Remotes: git remote"
+ git remote
+ cd ..
+ else
+ echo "INFO: Did not add Github fork name for UPSTREAM. Did not add REMOTE"
+ fi
+else
+ echo "ERROR: Argument not present: GitHub Repository Name"
+ echo $USAGE
+ exit 1
+fi
diff --git a/scancode/utils/scan_all.sh b/scancode/utils/scan_all.sh
new file mode 100755
index 0000000..aa5ba25
--- /dev/null
+++ b/scancode/utils/scan_all.sh
@@ -0,0 +1,16 @@
+#!/bin/bash
+# Licensed to the Apache Software Foundation (ASF) under one or more contributor
+# license agreements; and to You under the Apache License, Version 2.0.
+
+if [ $1 ]
+then
+ while read fn; do
+ cd incubator-openwhisk-utilities
+ echo "scanning repo:" $fn
+ scancode/scanCode.py --config scancode/ASF-Release.cfg ../$fn
+ cd ..
+ done < $1
+else
+ echo "ERROR: Argument not present: Repository Text listing (.txt)"
+ exit 1
+fi
diff --git a/scancode/utils/update_all.sh b/scancode/utils/update_all.sh
new file mode 100755
index 0000000..6374e3e
--- /dev/null
+++ b/scancode/utils/update_all.sh
@@ -0,0 +1,16 @@
+#!/bin/bash
+# Licensed to the Apache Software Foundation (ASF) under one or more contributor
+# license agreements; and to You under the Apache License, Version 2.0.
+
+if [ $1 ]
+then
+ while read fn; do
+ echo "update-fork:" $fn
+ cd $fn
+ git update-fork
+ cd ..
+ done < $1
+else
+ echo "ERROR: Argument not present: Repository Text listing (.txt)"
+ exit 1
+fi