5a057b0be2f6db8f74c1432ab4726444371d5955
[feisty_meow.git] / scripts / rev_control / report_new.sh
1 #!/bin/bash
2 # this script reports files that are not checked in yet in a set of folders.
3 # it works with subversion only, since git handles new files well whereas
4 # subversion ignores them until you tell it about them.  this script can take
5 # a directory as a parameter, but will default to the current directory.
6 # all the directories under the passed directory will be examined.
7
8 source "$FEISTY_MEOW_SCRIPTS/core/launch_feisty_meow.sh"
9 source "$FEISTY_MEOW_SCRIPTS/rev_control/version_control.sh"
10
11 save_terminal_title
12
13 ##############
14
15 dir="$1"; shift
16 if [ -z "$dir" ]; then
17   dir=.
18 fi
19
20 pushd "$dir" &>/dev/null
21 exit_on_error "changing directory to: $dir"
22 tempfile=$(generate_rev_ctrl_filelist)
23 exit_on_error "generating revision control file list"
24 popd &>/dev/null
25
26 perform_revctrl_action_on_file "$tempfile" do_revctrl_report_new
27 exit_on_error "running revision control report"
28
29 restore_terminal_title
30