Develop and Download Open Source Software

Browse CVS Repository

Contents of /pal/site/src/script/create_portlet_repository.sh

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (show annotations) (download) (as text)
Sun Jan 21 21:55:42 2007 UTC (17 years, 1 month ago) by shinsuke
Branch: MAIN
File MIME type: text/x-sh
add script to create rpad config file.

1 #!/bin/sh
2
3 rm -f /tmp/files.html
4 wget --header="Accept-Language: en" -O /tmp/files.html http://sourceforge.jp/projects/pal/files/
5 LINES=`iconv -f EUC-JP -t UTF-8 /tmp/files.html | grep -n "HTML Table ()" | sed -e "s/\(.*\):.*/\1/" | sed "1,2d"`
6
7 RUN_COMMAND="sed -e 1,"
8 SEPARATOR="d -e "
9 for line_num in `echo $LINES` ; do
10 RUN_COMMAND="$RUN_COMMAND$line_num$SEPARATOR";
11 SEPARATOR="";
12 done
13 RUN_COMMAND="$RUN_COMMAND,\$d /tmp/files.html";
14
15 echo "<?xml version=\"1.0\" encoding=\"UTF-8\"?>"
16 echo "<repository>"
17 #$RUN_COMMAND | sed -e "s/<a href=\"\([^\"]*\)\">/\1 /g" -e "s/<[^>]*>/ /g" -e "s/&nbsp;/ /g" -e "s/^ *//g"
18 $RUN_COMMAND | perl -pi -e "s/\r//g" | perl -pi -e "s/\n//g" | perl -pi -e "s/\<\/TR\>/\<\/TR\>\n/g"|sed -e "s/&nbsp;/ /g" -e "s/<a href=\"\([^\"]*\)\">/\1 /g" -e "s/<[^>]*>/ /g" -e "s/ */ /g" -e "s/ - \[.*//g" | grep -v zip |grep -v tar.gz | grep -v jar | perl -pi -e "s/\n//g" | perl -pi -e "s/ /\n/g"|grep http|sed -e "s/^ //g" | sed -e "s/prdownloads\.sourceforge\.jp/osdn.dl.sourceforge.jp/g" -e "s/\(20[0-9][0-9]-[0-9][0-9]-[0-9][0-9]\) \([0-9][0-9]:[0-9][0-9]\)/\1T\2+09:00/" -e "s/\([0-9][^ ]*\) \(http[^ ]*\) \([^ ][^ ]*\)\.war .*\(20[0-9][0-9]-[0-9][0-9]-[0-9][0-9]T[0-9][0-9]:[0-9][0-9]+[0-9][0-9]:[0-9][0-9]\).*/\n\
19 <portlet created=\"\4\" last-modified=\"\4\">\n\
20 <portlet-spec-version>\1<\/portlet-spec-version>\n\
21 <group-id>jp.sf.pal<\/group-id>\n\
22 <artifact-id>\3<\/artifact-id>\n\
23 <packaging>war<\/packaging>\n\
24 <version>\1<\/version>\n\
25 <name>\3<\/name>\n\
26 <description\/>\n\
27 <categories>\n\
28 <cateogry>PALab<\/cateogry>\n\
29 <\/categories>\n\
30 <publisher>\n\
31 <name>Portal Application Laboratory<\/name>\n\
32 <url>http:\/\/pal.sourceforge.jp\/<\/url>\n\
33 <\/publisher>\n\
34 <url>\n\
35 <binary>\2<\/binary>\n\
36 <source\/>\n\
37 <thumbnail\/>\n\
38 <\/url>\n\
39 <dependencies\/>\n\
40 <licenses>\n\
41 <license>\n\
42 <name>The Apache Software License, Version 2.0<\/name>\n\
43 <url>http:\/\/www.apache.org\/licenses\/LICENSE-2.0.txt<\/url>\n\
44 <distribution>repo<\/distribution>\n\
45 <\/license>\n\
46 <\/licenses>\n\
47 <java-version>\n\
48 <build>1.5<\/build>\n\
49 <runtime>1.5<\/runtime>\n\
50 <\/java-version>\n\
51 <locale-config>\n\
52 <default-locale>en<\/default-locale>\n\
53 <supported-locale>ja<\/supported-locale>\n\
54 <\/locale-config>\n\
55 <\/portlet>\n\
56 /g"
57 echo "</repository>"
58
59

Back to OSDN">Back to OSDN
ViewVC Help
Powered by ViewVC 1.1.26