Skip to content

Commit

Permalink
Merge 58d1177 into 306ceed
Browse files Browse the repository at this point in the history
  • Loading branch information
tomkralidis committed Apr 10, 2023
2 parents 306ceed + 58d1177 commit 681b96f
Show file tree
Hide file tree
Showing 28 changed files with 272 additions and 863 deletions.
559 changes: 0 additions & 559 deletions CHANGES.rst

This file was deleted.

2 changes: 1 addition & 1 deletion MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
include *.txt
include LICENSE
include *.rst
include *.md
86 changes: 49 additions & 37 deletions README.rst → README.md
Original file line number Diff line number Diff line change
@@ -1,21 +1,10 @@
OWSLib
======
# OWSLib

.. image:: https://github.com/geopython/OWSLib/workflows/build%20%E2%9A%99%EF%B8%8F/badge.svg
:target: https://github.com/geopython/OWSLib/actions
:alt: Build Status
[![Build](https://github.com/geopython/OWSLib/workflows/main.yml/badge.svg)](https://github.com/geopython/OWSLib/actions)
[![License](https://img.shields.io/github/license/geopython/OWSLib.svg)](https://github.com/geopython/OWSLib/blob/master/LICENSE)
[![Chat](https://badges.gitter.im/geopython/OWSLib.svg)](https://app.gitter.im/#/room/#geopython_owslib:gitter.im)

.. image:: https://api.codacy.com/project/badge/Grade/09f15588c99943e3976cdf20b7b32c8d
:target: https://www.codacy.com/project/cehbrecht/OWSLib/dashboard?utm_source=github.com&utm_medium=referral&utm_content=geopython/OWSLib&utm_campaign=Badge_Grade_Dashboard
:alt: Codacy Check

.. image:: https://img.shields.io/github/license/geopython/OWSLib.svg
:target: https://github.com/geopython/OWSLib/blob/master/LICENSE
:alt: GitHub license

.. image:: https://badges.gitter.im/geopython/OWSLib.svg
:target: https://gitter.im/geopython/OWSLib?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge
:alt: Join the chat at https://gitter.im/geopython/OWSLib
## Overview

OWSLib is a Python package for client programming with Open Geospatial
Consortium (OGC) web service (hence OWS) interface standards, and their
Expand All @@ -26,31 +15,55 @@ Full documentation is available at http://geopython.github.io/OWSLib
OWSLib provides a common API for accessing service metadata and wrappers for
numerous OGC Web Service interfaces.

Dependencies
------------
## Installation

The easiest way to install pywis-pubsub is via the Python [pip](https://pip.pypa.io)
utility:

```bash
pip3 install pywis-pubsub
```

## Requirements

- Python 3
- [virtualenv](https://virtualenv.pypa.io)

### Dependencies

Dependencies are listed in [requirements.txt](requirements.txt). Dependencies
are automatically installed during OWSLib installation.

### Installing OWSLib

OWSLib requires elementtree (standard in 2.5 as xml.etree) or lxml.
```bash
# setup virtualenv
python3 -m venv owslib
cd owslib
source bin/activate

Installation
------------
# clone codebase and install
git clone https://github.com/geopython/OWSLib.git
cd OWSLib
python3 setup.py install
```

See http://geopython.github.io/OWSLib/#installation
## Running

Usage
-----
Find out what a WMS has to offer. Service metadata:

Find out what a WMS has to offer. Service metadata::
```python

>>> from owslib.wms import WebMapService
>>> wms = WebMapService('http://wms.jpl.nasa.gov/wms.cgi', version='1.1.1')
>>> wms.identification.type
'OGC:WMS'
>>> wms.identification.version
'1.1.1'
>>> wms.identification.title
'JPL Global Imagery Service'
>>> wms.identification.abstract
'WMS Server maintained by JPL, worldwide satellite imagery.'
>>> from owslib.wms import WebMapService
>>> wms = WebMapService('http://wms.jpl.nasa.gov/wms.cgi', version='1.1.1')
>>> wms.identification.type
'OGC:WMS'
>>> wms.identification.version
'1.1.1'
>>> wms.identification.title
'JPL Global Imagery Service'
>>> wms.identification.abstract
'WMS Server maintained by JPL, worldwide satellite imagery.'

Available layers::

Expand Down Expand Up @@ -132,9 +145,8 @@ Releasing
.. code-block:: bash

# update version
vi VERSION.txt
vi owslib/__init__.py
git commit -m 'update release version' VERSION.txt owslib/__init__.py
git commit -m 'update release version' owslib/__init__.py
# push changes
git push origin master
git tag -a x.y.z -m 'tagging OWSLib release x.y.z'
Expand Down
1 change: 0 additions & 1 deletion VERSION.txt

This file was deleted.

189 changes: 14 additions & 175 deletions docs/Makefile
Original file line number Diff line number Diff line change
@@ -1,181 +1,20 @@
# Makefile for Sphinx documentation
# Minimal makefile for Sphinx documentation
#
# $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $$lang $(BUILDDIR)/$$lang;
#

# You can set these variables from the command line.
BUILDDIR = build
SPHINXOPTS =
SPHINXBUILD = sphinx-build
PAPER =
TRANSLATIONS =
LANGUAGES = en $(TRANSLATIONS)

# Internal variables.
PAPEROPT_a4 = -D latex_paper_size=a4
PAPEROPT_letter = -D latex_paper_size=letter
ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees/$$lang $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) -c . -A language=$$lang -D language=$$lang -A target=$(TARGET) -A languages='$(LANGUAGES)'

.PHONY: help clean html web pickle htmlhelp latex changes linkcheck
# You can set these variables from the command line, and also
# from the environment for the first two.
SPHINXOPTS ?=
SPHINXBUILD ?= sphinx-build
SOURCEDIR = source
BUILDDIR = build

# Put it first so that "make" without argument is like "make help".
help:
@echo "Please use \`make <target>' where <target> is one of"
@echo " html to make standalone HTML files"
@echo " init to preprocess translation directories"
@echo " pickle to make pickle files"
@echo " json to make JSON files"
@echo " htmlhelp to make HTML files and a HTML help project"
@echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter"
@echo " all-pdf to make PDF file"
@echo " all-ps to make PS file"
@echo " changes to make an overview over all changed/added/deprecated items"
@echo " linkcheck to check all external links for integrity"

clean:
-rm -rf $(BUILDDIR)/*

init:
@for lang in $(TRANSLATIONS) ;\
do \
# We change the Internal Field Separator (IFS) because to handle filename with special char like space. \
OLDIFS="$$IFS"; \
IFS=$$'\n'; \
for file in `cd en; find . -type f -a -regex '.*\.txt$$' -a -not -regex '.*\.svn.*' -printf "%p\n" ; cd ..;`; \
do \
if [ ! -f $$lang/$$file ]; then \
mkdir -p `dirname "$$lang/$$file"`; \
(echo ".. meta::"; echo " :ROBOTS: NOINDEX") | cat - "en/$$file" > "$$lang/$$file"; \
fi \
done; \
IFS=$$OLDIFS; \
# Copy all no .txt files \
yes n | cp -ipR en/* $$lang &> /dev/null; \
done
@echo "Init finished. Other targets can now be built.";\

html:
@for lang in $(LANGUAGES);\
do \
mkdir -p $(BUILDDIR)/html/$$lang $(BUILDDIR)/doctrees/$$lang; \
echo "$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $$lang $(BUILDDIR)/html/$$lang";\
$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $$lang $(BUILDDIR)/html/$$lang;\
done
@echo
@echo "Build finished. The HTML pages are in $(BUILDDIR)/html/<language>.";\

singlehtml:
@for lang in $(LANGUAGES);\
do \
mkdir -p $(BUILDDIR)/singlehtml/$$lang $(BUILDDIR)/doctrees/$$lang; \
$(SPHINXBUILD) -b singlehtml $(ALLSPHINXOPTS) $$lang $(BUILDDIR)/singlehtml/$$lang;\
done
@echo
@echo "Build finished. The HTML pages are in $(BUILDDIR)/singlehtml/<language>.";\

pickle:
@for lang in $(LANGUAGES);\
do \
mkdir -p $(BUILDDIR)/pickle/$$lang $(BUILDDIR)/doctrees/$$lang; \
$(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $$lang $(BUILDDIR)/pickle/$$lang;\
done
@echo
@echo "Build finished; now you can process the pickle files."

web: pickle

json:
@for lang in $(LANGUAGES);\
do \
mkdir -p $(BUILDDIR)/json/$$lang $(BUILDDIR)/doctrees/$$lang; \
$(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $$lang $(BUILDDIR)/json/$$lang;\
done
@echo
@echo "Build finished; now you can process the JSON files."

htmlhelp:
@for lang in $(LANGUAGES);\
do \
mkdir -p $(BUILDDIR)/htmlhelp/$$lang $(BUILDDIR)/doctrees/$$lang; \
$(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $$lang $(BUILDDIR)/htmlhelp/$$lang;\
done
@echo
@echo "Build finished; now you can run HTML Help Workshop with the" \
".hhp project file in $(BUILDDIR)/htmlhelp/<language>."

latex:
@for lang in $(LANGUAGES);\
do \
mkdir -p $(BUILDDIR)/latex/$$lang $(BUILDDIR)/doctrees/$$lang; \
$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $$lang $(BUILDDIR)/latex/$$lang;\
done
@echo
@echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex/<language>."\
@echo "Run \`make all-pdf' or \`make all-ps'"

pdf:
@for lang in $(LANGUAGES);\
do \
mkdir -p $(BUILDDIR)/pdf/$$lang $(BUILDDIR)/doctrees/$$lang; \
$(SPHINXBUILD) -b pdf $(ALLSPHINXOPTS) $$lang $(BUILDDIR)/pdf/$$lang;\
done
@echo
@echo "Build finished; the PDF files are in $(BUILDDIR)/pdf/<language>."\
@echo "Run \`make pdf' "

epub:
@for lang in en;\
do \
mkdir -p $(BUILDDIR)/epub/$$lang $(BUILDDIR)/doctrees/$$lang; \
$(SPHINXBUILD) -b epub $(ALLSPHINXOPTS) $$lang $(BUILDDIR)/epub/$$lang;\
done
@echo
@echo "Build finished; the epub files are in $(BUILDDIR)/epub/<language>."\
@echo "Run \`make epub' "

all-pdf:
@for lang in $(LANGUAGES);\
do \
/usr/bin/make -C $(BUILDDIR)/latex/$$lang all-pdf ; \
if [ -d $(BUILDDIR)/html/$$lang ]; then \
mv -f $(BUILDDIR)/latex/$$lang/OWSLib.pdf $(BUILDDIR)/html/$$lang ; \
fi \
done

all-ps:
@for lang in $(LANGUAGES);\
do \
/usr/bin/make -C $(BUILDDIR)/latex/$$lang all-ps ; \
if [ -d $(BUILDDIR)/html/$$lang ]; then \
mv -f $(BUILDDIR)/latex/$$lang/OWSLib.pdf $(BUILDDIR)/html/$$lang ; \
fi \
done

changes:
@for lang in $(LANGUAGES);\
do \
mkdir -p $(BUILDDIR)/changes/$$lang $(BUILDDIR)/doctrees/$$lang; \
$(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $$lang $(BUILDDIR)/changes/$$lang;\
done
@echo
@echo "The overview file is in $(BUILDDIR)/changes/<language>."
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)

linkcheck:
@for lang in $(LANGUAGES);\
do \
mkdir -p $(BUILDDIR)/linkcheck/$$lang $(BUILDDIR)/doctrees/$$lang; \
$(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $$lang $(BUILDDIR)/linkcheck/$$lang;\
done
@echo
@echo "Link check complete; look for any errors in the above output " \
"or in $(BUILDDIR)/linkcheck/<language>/output.txt."
.PHONY: help Makefile

labels:
@for lang in $(LANGUAGES);\
do \
mkdir -p $(BUILDDIR)/labels/$$lang $(BUILDDIR)/doctrees/$$lang; \
$(SPHINXBUILD) -b labels $(ALLSPHINXOPTS) $$lang $(BUILDDIR)/labels/$$lang;\
cp $(BUILDDIR)/labels/$$lang/labels.txt $$lang/include/labels.inc;\
done
@echo
@echo "Label generation complete; look for any errors in the above output " \
"or in $(BUILDDIR)/labels/<language>/labels.txt."
# Catch-all target: route all unknown targets to Sphinx using the new
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
%: Makefile
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
12 changes: 0 additions & 12 deletions docs/en/logging.rst

This file was deleted.

1 change: 0 additions & 1 deletion docs/en/notebooks

This file was deleted.

16 changes: 0 additions & 16 deletions docs/publish.sh

This file was deleted.

5 changes: 5 additions & 0 deletions docs/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
ipykernel
nbconvert
nbsphinx
pypandoc
sphinx
File renamed without changes
File renamed without changes.
Loading

0 comments on commit 681b96f

Please sign in to comment.