- Improve README

- check rpm db of installed packages first 

- Adding simple changelog generator 

- Update installation strategy 

- Fix ./setup.py install 

- Adding travis.yml file 

- Initial commit

OBS-URL: https://build.opensuse.org/package/show/Virtualization:containers/obs-service-replace_using_package_version?expand=0&rev=1
This commit is contained in:
David Cassany 2018-03-20 07:26:08 +00:00 committed by Git OBS Bridge
commit eb9650b50d
5 changed files with 136 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

1
.gitignore vendored Normal file
View File

@ -0,0 +1 @@
.osc

View File

@ -0,0 +1,34 @@
-------------------------------------------------------------------
Mon Mar 19 18:22:25 2018 +0100 dcassany@suse.com
- Improve README
-------------------------------------------------------------------
Mon Mar 19 16:12:27 2018 +0100 dcassany@suse.com
- check rpm db of installed packages first
-------------------------------------------------------------------
Mon Mar 19 14:52:12 2018 +0100 dcassany@suse.com
- Adding simple changelog generator
-------------------------------------------------------------------
Mon Mar 12 17:00:04 2018 +0100 dcassany@suse.com
- Update installation strategy
-------------------------------------------------------------------
Thu Mar 8 20:40:57 2018 +0100 dcassany@suse.com
- Fix ./setup.py install
-------------------------------------------------------------------
Thu Mar 8 20:06:11 2018 +0100 dcassany@suse.com
- Adding travis.yml file
-------------------------------------------------------------------
Thu Mar 8 19:14:44 2018 +0100 dcassany@suse.com
- Initial commit

View File

@ -0,0 +1,75 @@
#
# spec file for package obs-service-replace_with_package_version
#
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
%define service replace_using_package_version
Name: obs-service-%{service}
Version: 0.0.1
Release: 0
Summary: An OBS service: Replaces a regex with the version value of a package
License: GPL-3.0+
Group: Development/Tools/Building
Url: https://github.com/openSUSE/obs-service-%{service}
Source0: %{service}-%{version}.tar.gz
%if 0%{?suse_version} > 1315
BuildRequires: python3-setuptools
Requires: python3-setuptools
Requires: python3-docopt
%else
BuildRequires: python-setuptools
Requires: python-setuptools
Requires: python-docopt
%endif
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildArch: noarch
%description
This service replaces a given regex with the version value of
a given package. Can be used to align the version of you package or image
to the version of another package.
%prep
%setup -q -n %{service}-%{version}
%build
%if 0%{?suse_version} > 1315
# Build Python 3 version
python3 setup.py build
%else
# Build Python 2 version
python2 setup.py build
%endif
%install
%if 0%{?suse_version} > 1315
# Install Python 3 version
python3 setup.py install --root %{buildroot} \
--install-script %{_prefix}/lib/obs/service \
--install-data %{_prefix}/lib/obs/service
%else
# Install Python 2 version
python2 setup.py install --root %{buildroot} \
--install-script %{_prefix}/lib/obs/service \
--install-data %{_prefix}/lib/obs/service
%endif
%files
%defattr(-,root,root)
%dir %{_prefix}/lib/obs
%dir %{_prefix}/lib/obs/service
%{_prefix}/lib/obs/service
%changelog

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:a3b61d839820b87cd35f1a99913a637886260c4bf62face2bbd44f34494051ec
size 3154