summaryrefslogtreecommitdiff
path: root/mail/pkg/tools
diff options
context:
space:
mode:
authorKali Kaneko (leap communications) <kali@leap.se>2016-08-29 23:05:33 -0400
committerKali Kaneko (leap communications) <kali@leap.se>2016-08-29 23:05:33 -0400
commit43df4205af42fce5d097f70bb0345b69e9d16f1c (patch)
tree3850a0ed0748476b37e2850bbdc10d10aadfbbbd /mail/pkg/tools
parentaa882b7a64f2c821c8e241a5ff725f27c64fc15f (diff)
parent8e4746835a1a053558ff06d4fd12b31167a80296 (diff)
Merge leap_mail into unified bitmask repo
Diffstat (limited to 'mail/pkg/tools')
-rwxr-xr-xmail/pkg/tools/get_authors.sh2
-rwxr-xr-xmail/pkg/tools/with_venvwrapper.sh16
2 files changed, 18 insertions, 0 deletions
diff --git a/mail/pkg/tools/get_authors.sh b/mail/pkg/tools/get_authors.sh
new file mode 100755
index 00000000..0169bb17
--- /dev/null
+++ b/mail/pkg/tools/get_authors.sh
@@ -0,0 +1,2 @@
+#!/bin/sh
+git log --format='%aN <%aE>' | awk '{arr[$0]++} END{for (i in arr){print arr[i], i;}}' | sort -rn | cut -d' ' -f2-
diff --git a/mail/pkg/tools/with_venvwrapper.sh b/mail/pkg/tools/with_venvwrapper.sh
new file mode 100755
index 00000000..693c0ac9
--- /dev/null
+++ b/mail/pkg/tools/with_venvwrapper.sh
@@ -0,0 +1,16 @@
+#!/bin/bash
+
+#Wraps a command in a virtualenwrapper passed as first argument.
+#Example:
+#with_virtualenvwrapper.sh leap-bitmask ./run_tests.sh
+
+wd=`pwd`
+alias pyver='python -c "import $1;print $1.__path__[0]; print $1.__version__;"'
+
+source `which virtualenvwrapper.sh`
+echo "Activating virtualenv " $1
+echo "------------------------------------"
+workon $1
+cd $wd
+echo "running version: " `pyver leap.bitmask`
+$2 $3 $4 $5