]> git.pld-linux.org Git - packages/jquery-datepicker.git/blob - jquery-datepicker.spec
099c51bd2a97ef8932c7fc7e60b9015f07cb029f
[packages/jquery-datepicker.git] / jquery-datepicker.spec
1 %define         svnrev  108
2 %define         rel             1
3 %define         plugin  datepicker
4 Summary:        A flexible unobtrusive calendar component for jQuery
5 Name:           jquery-%{plugin}
6 # last tag is 2.1.2, so no actual version of package
7 Version:        2.1.2
8 Release:        0.%{svnrev}.%{rel}
9 License:        MIT
10 Group:          Applications/WWW
11 # svn export http://jquery-datepicker.googlecode.com/svn/tags/2.1.2 jquery-datepicker-2.1.2
12 # tar cjf jquery-datepicker-2.1.2.tar.bz2 jquery-datepicker-2.1.2
13 Source0:        %{name}-%{version}.tar.bz2
14 Source1:        http://www.kelvinluck.com/assets/jquery/datePicker/v2/demo/scripts/jquery.datePicker.js
15 # Source0-md5:  df393f932ff6d5a37d4a0856c1cbb216
16 URL:            http://www.kelvinluck.com/assets/jquery/datePicker/v2/demo/
17 BuildRequires:  js
18 BuildRequires:  rpmbuild(macros) >= 1.565
19 BuildRequires:  yuicompressor
20 Requires:       jquery >= 1.3
21 BuildArch:      noarch
22 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
23
24 %define         _appdir %{_datadir}/jquery/%{plugin}
25
26 %description
27 jQuery datepicker is a jQuery plugin which allows you to easily add
28 "date picker" calendars to you HTML forms. These calendars make it
29 much quicker, easier and less error prone for people to input certain
30 types of dates.
31
32 %package demo
33 Summary:        Demo for jQuery.datePicker
34 Summary(pl.UTF-8):      Pliki demonstracyjne dla pakietu jQuery.datePicker
35 Group:          Development
36 Requires:       %{name} = %{version}-%{release}
37
38 %description demo
39 Demonstrations and samples for jQuery.datePicker.
40
41 %prep
42 %setup -q
43 cp -p %{SOURCE1} dist
44
45 %build
46 install -d build
47
48 # compress .js
49 js=dist/jquery.datePicker.js
50 out=build/jquery.datePicker.js
51 %if 0%{!?debug:1}
52 yuicompressor --charset UTF-8 $js -o $out
53 js -C -f $out
54 %else
55 cp -p $js $out
56 %endif
57
58 # pack .css
59 css=demo/styles/datePicker.css
60 out=build/datePicker.css
61 %if 0%{!?debug:1}
62 yuicompressor --charset UTF-8 $css -o $out
63 %else
64 cp -p $css $out
65 %endif
66
67 %install
68 rm -rf $RPM_BUILD_ROOT
69 install -d $RPM_BUILD_ROOT{%{_appdir},%{_examplesdir}/%{name}-%{version}}
70 cp -p build/jquery.datePicker.js $RPM_BUILD_ROOT%{_appdir}
71 cp -p build/datePicker.css $RPM_BUILD_ROOT%{_appdir}
72
73 cp -a demo/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
74
75 %clean
76 rm -rf $RPM_BUILD_ROOT
77
78 %files
79 %defattr(644,root,root,755)
80 %{_appdir}
81
82 %files demo
83 %defattr(644,root,root,755)
84 %{_examplesdir}/%{name}-%{version}
This page took 0.444324 seconds and 2 git commands to generate.