From 37f833aec1f31e9f42e7bee497b627d8c00ba6a4 Mon Sep 17 00:00:00 2001 From: Wouter R Date: Fri, 8 Jan 2016 23:24:03 +0100 Subject: [PATCH] Print skipped files when adding copyright notices. Remove old script. --- extra/scripts/attach-license.lua | 2 ++ src/script/collect-code.sh | 34 -------------------------------- 2 files changed, 2 insertions(+), 34 deletions(-) delete mode 100755 src/script/collect-code.sh diff --git a/extra/scripts/attach-license.lua b/extra/scripts/attach-license.lua index aff1024..1d1e184 100755 --- a/extra/scripts/attach-license.lua +++ b/extra/scripts/attach-license.lua @@ -254,6 +254,8 @@ local function main() else print("error: file '" .. f .. "' has uncommitted changes in git, refusing to process") end + elseif processType == false then + print("Skipping excluded file '" .. f .. "'") end end end diff --git a/src/script/collect-code.sh b/src/script/collect-code.sh deleted file mode 100755 index a41902b..0000000 --- a/src/script/collect-code.sh +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/sh - -BASE_NAME=d3d-wifibox-backup -SRC_PATHS="/etc /root /www/ /usr/share/lua" -TEMP_DIR=/tmp -TGT_FILE=$BASE_NAME.tar.gz - -if [ -e /www-external ]; then - echo "ERROR: switch back /www-regular to /www before running this script" - exit 1 -fi - -cd $TEMP_DIR -if [ $? != 0 ]; then - echo "ERROR: could not cd to temporary directory ($TEMP_DIR)" - exit 2 -fi - -TGT_DIR=$TEMP_DIR/$BASE_NAME -rm -rf $TGT_DIR -mkdir -p $TGT_DIR - -for path in $SRC_PATHS; do - echo "copying $path -> $TGT_DIR..." - cp -a $path $TGT_DIR -done - -echo "compressing $TGT_DIR into $BASE_NAME.tar.gz..." -tar czf $BASE_NAME.tar.gz $BASE_NAME - -echo "removing staging dir..." -rm -rf $TGT_DIR - -echo "done."