diff options
author | James E.H. Turner <jturner@gemini.edu> | 2016-09-01 19:50:06 -0400 |
---|---|---|
committer | James E.H. Turner <jturner@gemini.edu> | 2016-09-01 19:50:06 -0400 |
commit | 07945350c8f7f948e67879022c710f5aa0027b8a (patch) | |
tree | 8464f3886b334db9ef97400179da05a04838c94a /scripts | |
parent | 1e052387056cd49efecffc4dc3128d955f06956e (diff) | |
download | astroconda-iraf-helpers-07945350c8f7f948e67879022c710f5aa0027b8a.tar.gz |
Deprecate unmangle_interpreter script, in favour of running python directly on scripts with a messed-up interpreter path at install time (duh).
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/unmangle_interpreter | 48 |
1 files changed, 0 insertions, 48 deletions
diff --git a/scripts/unmangle_interpreter b/scripts/unmangle_interpreter deleted file mode 100755 index bdb7128..0000000 --- a/scripts/unmangle_interpreter +++ /dev/null @@ -1,48 +0,0 @@ -#!/bin/sh - -# Names of the script(s) to be updated in the same directory this is run from: -scripts="ac_update_extern_pkg" - -# Work in the directory where this script and those to be updated live: -cd `dirname "$0"` || exit 1 # (should never fail if this script can be executed) - -# Put temporary copies in a tmp/ directory in the conda environment or /tmp/: -tmp="$PREFIX/tmp" -if [ -d "$tmp" ]; then - remove_tmp=0 -else - if ! mkdir "$tmp"; then - echo "failed to create $tmp" >&2 - exit 1 - fi - remove_tmp=1 -fi - -# Update each named script in turn: -for script in $scripts; do - - if [ ! -r "$script" ]; then - echo "no such script: $script" >&2 - exit 1 - fi - - tmpscript="$tmp/$script" - - if ! sed -e 's|#\!.*/python|#\!/usr/bin/python|' "$script" > "$tmpscript" - then - echo "cannot write $tmpscript" >&2 - exit 1 - fi - - chmod 755 "$tmpscript" - - if ! mv -f "$tmpscript" "$script"; then - echo "failed to replace $script" >&2 - exit 1 - fi - -done - -# Clean up: -[ $remove_tmp == 1 ] && rmdir "$tmp" - |