From 8da1f0d66806e07b1fc2176e4758561839f5cbe6 Mon Sep 17 00:00:00 2001 From: Oleg Broytman Date: Sun, 27 Dec 2015 19:42:36 +0300 Subject: [PATCH] Export given treeish or HEAD --- mk-distr | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/mk-distr b/mk-distr index b3050ab..75a2774 100755 --- a/mk-distr +++ b/mk-distr @@ -1,12 +1,8 @@ #! /bin/sh -if [ -n "$1" ]; then - git checkout "$1" -fi && - umask 022 && -git archive --format=tar --prefix=m_lib/ HEAD | +git archive --format=tar --prefix=m_lib/ "${1:-HEAD}" | (cd "$HOME/tmp" && exec tar xf -) && cd "$HOME/tmp/m_lib" && -- 2.39.5