Name:           beust-jcommander
Version:        1.71
Release:        7
Summary:        Java framework for parsing command line parameters
License:        ASL 2.0
URL:            http://jcommander.org/
BuildArch:      noarch
Source0:        https://github.com/cbeust/jcommander/archive/%{version}.tar.gz
Source1:        beust-jcommander.pom
Patch0001:      0001-ParseValues-NullPointerException-patch.patch 
BuildRequires:  maven-local mvn(org.apache.felix:maven-bundle-plugin)
BuildRequires:  mvn(org.sonatype.oss:oss-parent:pom:) mvn(org.testng:testng)

%description
JCommander is a very small Java framework that makes it trivial to
parse command line parameters.

%package help
Summary:        API documentation for beust-jcommander

Provides:       beust-jcommander-javadoc = %{version}-%{release}
Obsoletes:      beust-jcommander-javadoc < %{version}-%{release}

%description help
This package contains the API documentation for beust-jcommander.

%prep
%autosetup -n jcommander-%{version} -p1

chmod -x license.txt
cp -p %SOURCE1 pom.xml
sed -i 's/@VERSION@/%{version}/g' pom.xml

%build
%mvn_file : beust-jcommander
%mvn_build

%install
%mvn_install

%files -f .mfiles
%doc license.txt notice.md README.markdown

%files help -f .mfiles-javadoc

%changelog
* Fri Feb 28 2020 daiqianwen <daiqianwen@huawei.com> - 1.71-7
- Modify patch

* Wed Feb 12 2020 Shuaishuai Song <songshuaishuai2@huawei.com> - 1.71-6
- Package init
