File: backup

package info (click to toggle)
code-saturne 6.0.2-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, sid
  • size: 63,340 kB
  • sloc: ansic: 354,724; f90: 119,812; python: 87,716; makefile: 4,653; cpp: 4,272; xml: 2,839; sh: 1,228; lex: 170; yacc: 100
file content (25 lines) | stat: -rwxr-xr-x 457 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#!/bin/sh

PREFIX=`dirname $0`
PREFIX=`cd "$PREFIX/.." ; pwd`
SUBDIR=`basename $PREFIX`

ARCHNAME=${SUBDIR}.tar.xz

RUNDIR=`pwd`

cd $PREFIX/.. || exit 1

PREFIX_BASE=`basename $PREFIX`

tar cvJf $ARCHNAME --exclude='.*.swp' \
                   --exclude='build' \
                   --exclude='arch' \
                   --exclude='neptune_cfd' \
                   --exclude=$ARCHNAME \
                   $PREFIX_BASE

mv $ARCHNAME $RUNDIR

cd $RUNDIR