~ubuntu-branches/ubuntu/vivid/ubuntu-kylin-docs/vivid

« back to all changes in this revision

Viewing changes to ubuntu-kylin-help/C/check_releases.sh

  • Committer: Package Import Robot
  • Author(s): Lei Luo
  • Date: 2014-04-10 14:58:12 UTC
  • Revision ID: package-import@ubuntu.com-20140410145812-9mfgq3xleqy0l89f
Tags: 14.04.3

* Add "Replaces" field in debian control file to automatically remove
  ubuntu-docs before installation.
* Merge ubuntu-docs changes.
* Update zh_CN tranlation.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#!/bin/bash
 
2
 
 
3
# Produce a list of all .page files containing
 
4
# outdated release names which may or may not
 
5
# need to be updated, depending on use.
 
6
#
 
7
# Instructions
 
8
# Type this command in the current directory to run this script:
 
9
# bash check_releases.sh
 
10
#
 
11
# DO NOT TRANSLATE
 
12
 
 
13
ReleaseNames=(
 
14
Warty
 
15
warty
 
16
Hoary
 
17
hoary
 
18
Breezy
 
19
breezy
 
20
Dapper
 
21
dapper
 
22
Edgy
 
23
edgy
 
24
Feisty
 
25
feisty
 
26
Gutsy
 
27
gutsy
 
28
Hardy
 
29
hardy
 
30
Intrepid
 
31
intrepid
 
32
Jaunty
 
33
jaunty
 
34
Karmic
 
35
karmic
 
36
Lucid
 
37
lucid
 
38
Maverick
 
39
maverick
 
40
Natty
 
41
natty
 
42
Oneiric
 
43
oneiric
 
44
Precise
 
45
precise
 
46
Quantal
 
47
quantal
 
48
Raring
 
49
raring
 
50
Saucy
 
51
saucy
 
52
);
 
53
 
 
54
for i in "${ReleaseNames[@]}"; # for each name in the ReleaseNames array above
 
55
        do # do the following:
 
56
                grep -q  $i *.page; # check all .page files for the release name
 
57
                if [ "$?" = "0" ]; # if you find it
 
58
                        then # then
 
59
                                echo; # display a blank line
 
60
                                echo "== These pages contain $i =="; # display this header with the release name
 
61
                                grep -l $i *.page; # display a list of the pages
 
62
                else # otherwise
 
63
                                : # do nothing
 
64
                fi; # finished with the .page files
 
65
        done; # done with the names in the array
 
66
exit 0; # exit with a status code of 0