Skip to content

Commit 7c43ab3

Browse files
committed
Make a python package out of the scripts
Signed-off-by: Adam Dybbroe <Adam.Dybbroe@smhi.se>
1 parent 28a70ee commit 7c43ab3

8 files changed

+216
-116
lines changed

.git_archival.txt

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
ref-names: $Format:%D$

.gitattributes

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
.git_archival.txt export-subst
File renamed without changes.

level1c4pps/seviri2pps.py bin/seviri2pps.py

+107-108
Large diffs are not rendered by default.

level1c4pps/__init__.py

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
#!/usr/bin/env python
2+
# -*- coding: utf-8 -*-
3+
4+
# Copyright (c) 2019 Adam.Dybbroe
5+
6+
# Author(s):
7+
8+
# Adam.Dybbroe <adam.dybbroe@smhi.se>
9+
10+
# This program is free software: you can redistribute it and/or modify
11+
# it under the terms of the GNU General Public License as published by
12+
# the Free Software Foundation, either version 3 of the License, or
13+
# (at your option) any later version.
14+
15+
# This program is distributed in the hope that it will be useful,
16+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
17+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18+
# GNU General Public License for more details.
19+
20+
# You should have received a copy of the GNU General Public License
21+
# along with this program. If not, see <http://www.gnu.org/licenses/>.
22+
23+
"""level1c4pps Package Initializer
24+
"""

setup.cfg

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
[options]
2+
setup_requires =
3+
setuptools_scm
4+
setuptools_scm_git_archive
5+
6+
[bdist_rpm]
7+
provides=level1c4pps
8+
requires=satpy
9+
10+
no-autoreq=True
11+
release=1
12+
13+
[bdist_wheel]
14+
universal=1
15+
16+
[flake8]
17+
max-line-length = 120
18+

setup.py

+65
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
#!/usr/bin/env python
2+
# -*- coding: utf-8 -*-
3+
4+
# Copyright (c) 2019 Pytroll
5+
6+
# Author(s):
7+
8+
# Nina Håkansson <nina.hakansson@smhi.se>
9+
# Erik Johansson <erik.johansson@smhi.se>
10+
# Adam Dybbroe <adam.dybbroe@smhi.se>
11+
12+
# This program is free software: you can redistribute it and/or modify
13+
# it under the terms of the GNU General Public License as published by
14+
# the Free Software Foundation, either version 3 of the License, or
15+
# (at your option) any later version.
16+
17+
# This program is distributed in the hope that it will be useful,
18+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
19+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20+
# GNU General Public License for more details.
21+
22+
# You should have received a copy of the GNU General Public License
23+
# along with this program. If not, see <http://www.gnu.org/licenses/>.
24+
25+
"""Scripts to convert various satellite level-1 data formats (e.g. SEVIRI level
26+
1.5 HRIT) to NWCSAF/PPS level-1c format
27+
28+
"""
29+
30+
from setuptools import find_packages, setup
31+
32+
try:
33+
# HACK: https://github.com/pypa/setuptools_scm/issues/190#issuecomment-351181286
34+
# Stop setuptools_scm from including all repository files
35+
import setuptools_scm.integration
36+
setuptools_scm.integration.find_files = lambda _: []
37+
except ImportError:
38+
pass
39+
40+
41+
NAME = "level1c4pps"
42+
README = open('README.md', 'r').read()
43+
44+
setup(name=NAME,
45+
# version=version.__version__,
46+
description='Tools to convert various satellite level-1 data formats to NWCSAF/PPS level-1c format',
47+
long_description=README,
48+
author='Nina Hakansson',
49+
author_email='nina.hakansson@smhi.se',
50+
classifiers=["Development Status :: 3 - Alpha",
51+
"Intended Audience :: Science/Research",
52+
"License :: OSI Approved :: GNU General Public License v3 " +
53+
"or later (GPLv3+)",
54+
"Operating System :: OS Independent",
55+
"Programming Language :: Python",
56+
"Topic :: Scientific/Engineering"],
57+
url="https://github.com:foua-pps/level1c4pps",
58+
packages=['level1c4pps', ],
59+
scripts=['bin/seviri2pps.py', 'bin/gac2pps.py', ],
60+
data_files=[],
61+
zip_safe=False,
62+
use_scm_version=True,
63+
python_requires='>=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*',
64+
install_requires=['satpy', 'pyorbital', 'trollsift', ],
65+
)

version.py

-8
This file was deleted.

0 commit comments

Comments
 (0)