File: 71_sh_bd_purge_add_shebang.dpatch

package info (click to toggle)
bandwidthd 2.0.1%2Bcvs20090917-4.1
  • links: PTS
  • area: main
  • in suites: squeeze
  • size: 1,064 kB
  • ctags: 560
  • sloc: sh: 13,357; ansic: 2,743; php: 1,235; yacc: 216; makefile: 160; lex: 36; sql: 27
file content (26 lines) | stat: -rw-r--r-- 953 bytes parent folder | download | duplicates (2)
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
26
#! /bin/sh /usr/share/dpatch/dpatch-run
## 71_sh_bd_purge_add_shebang.dpatch by Andreas Henriksson <andreas@fatal.se>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: Add proper script header and use for loop, since echo -e is bashism.

@DPATCH@
diff -urNad bandwidthd-2.0.1+cvs20071208~/phphtdocs/bd_pgsql_purge.sh bandwidthd-2.0.1+cvs20071208/phphtdocs/bd_pgsql_purge.sh
--- bandwidthd-2.0.1+cvs20071208~/phphtdocs/bd_pgsql_purge.sh	2005-01-07 20:40:41.000000000 +0100
+++ bandwidthd-2.0.1+cvs20071208/phphtdocs/bd_pgsql_purge.sh	2008-03-17 10:42:37.000000000 +0100
@@ -1,5 +1,7 @@
+#!/bin/sh
+
 echo "SET sort_mem TO 45000;"
-echo -e "bd_rx_log \n bd_tx_log \n bd_rx_total_log \n bd_tx_total_log" | while read TABLE; 
+for TABLE in bd_rx_log bd_tx_log bd_rx_total_log bd_tx_total_log
 do
 cat << EOF
 BEGIN;
@@ -49,4 +51,4 @@
 COMMIT;
 EOF
 done
-echo "VACUUM ANALYZE"
\ No newline at end of file
+echo "VACUUM ANALYZE"