Skip to content

Commit

Permalink
Merge pull request #1 from weaverba137/pre-0.3
Browse files Browse the repository at this point in the history
Changes in preparation for version 0.3
  • Loading branch information
weaverba137 authored Jan 17, 2017
2 parents 0ca906f + 096f1ca commit f73912b
Show file tree
Hide file tree
Showing 67 changed files with 1,826 additions and 4,427 deletions.
25 changes: 25 additions & 0 deletions .coveragerc
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
[run]
source = hpsspy
omit =
hpsspy/_version.py
hpsspy/conftest*
hpsspy/cython_version*
hpsspy/setup_package*
hpsspy/*/setup_package*
hpsspy/*/*/setup_package*
hpsspy/test/*

[report]
exclude_lines =
# Have to re-enable the standard pragma
pragma: no cover

# Don't complain about packages we have installed
except ImportError

# Don't complain if tests don't hit assertions
raise AssertionError
raise NotImplementedError

# Don't complain about script hooks
def main\(.*\):
7 changes: 3 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# Compiled files
*.py[cod]

# C extensions
Expand All @@ -13,16 +14,13 @@ parts
bin
var
sdist
MANIFEST
develop-eggs
.installed.cfg
lib
lib64
__pycache__

# Other generated files
*/version.py
hpsspy/hpsspy.cfg

# Sphinx
_build
_static
Expand All @@ -32,6 +30,7 @@ _generated
pip-log.txt

# Unit test / coverage reports
htmlcov/
.coverage
.tox
nosetests.xml
Expand Down
81 changes: 81 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
#
# IMPORTANT. OS X support is so experimental that you have to specifically
# request to have it enabled, on a per-repository basis. See
# http://docs.travis-ci.com/user/multi-os/#Manual-intervention-required
#
# This file will still work, without OS X enabled, it just won't run those
# tests.
#
language: python

os:
- linux
# - osx

# Setting sudo to false opts in to Travis-CI container-based builds.
sudo: false

# The apt packages below are needed for sphinx builds, which can no longer
# be installed with sudo apt-get.
addons:
apt:
packages:
- graphviz
- texlive-latex-extra
- dvipng
python:
- 2.7
- 3.3
- 3.4
- 3.5
env:
global:
# The following versions are the 'default' for tests, unless
# overidden underneath. They are defined here in order to save having
# to repeat them for all configurations.
- MAIN_CMD='python setup.py'
matrix:
- SETUP_CMD='egg_info'
- SETUP_CMD='bdist_egg'
- SETUP_CMD='test'

matrix:
# Don't wait for allowed failures.
fast_finish: true

# OS X support is still experimental, so don't penalize failuures.
allow_failures:
- os: osx

include:
# Check for sphinx doc build warnings - we do this first because it
# runs for a long time
- os: linux
python: 3.5
env: SETUP_CMD='build_sphinx'
# -w is an astropy extension

# Coverage test, pass the results to coveralls.
- os: linux
python: 3.5
env: MAIN_CMD='coverage' SETUP_CMD='run hpsspy/test/hpsspy_test_suite.py'

# PEP 8 compliance.
- os: linux
python: 3.5
env: MAIN_CMD='pep8' SETUP_CMD='--count hpsspy'

# before_install:
# - curl ipinfo.io

install:
- if [[ $MAIN_CMD == 'pep8' ]]; then pip install pep8; fi
- if [[ $SETUP_CMD == 'build_sphinx' ]]; then pip install Sphinx; fi
- if [[ $MAIN_CMD == 'coverage' ]]; then pip install coverage coveralls; fi
# - pip install -r requirements.txt

script:
- $MAIN_CMD $SETUP_CMD

after_success:
- if [[ $MAIN_CMD == 'coverage' ]]; then coveralls; fi
2 changes: 1 addition & 1 deletion LICENSE.rst
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2014, Benjamin Alan Weaver <[email protected]>
Copyright (c) 2014-2017, Benjamin Alan Weaver <[email protected]>
All rights reserved.

Redistribution and use in source and binary forms, with or without modification,
Expand Down
3 changes: 0 additions & 3 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
include LICENSE.rst
include README.rst
include ez_setup.py

graft doc

prune doc/_build
32 changes: 28 additions & 4 deletions README.rst
Original file line number Diff line number Diff line change
@@ -1,11 +1,35 @@
======
hpsspy
HPSSPy
======

.. image:: https://img.shields.io/pypi/l/hpsspy.svg
:target: https://pypi.python.org/pypi/hpsspy
:alt: License

.. image:: https://img.shields.io/pypi/v/hpsspy.svg
:target: https://pypi.python.org/pypi/hpsspy
:alt: PyPI Badge

.. image:: https://img.shields.io/pypi/dm/hpsspy.svg
:target: https://pypi.python.org/pypi/hpsspy
:alt: PyPI Downloads

.. image:: https://img.shields.io/travis/weaverba137/hpsspy.svg
:target: https://travis-ci.org/weaverba137/hpsspy
:alt: Travis Build Status

.. image:: https://coveralls.io/repos/github/weaverba137/hpsspy/badge.svg?branch=pre-0.3
:target: https://coveralls.io/github/weaverba137/hpsspy?branch=pre-0.3
:alt: Test Coverage Status

.. image:: https://readthedocs.org/projects/hpsspy/badge/?version=pre-0.3
:target: http://hpsspy.readthedocs.io/en/latest/?badge=pre-0.3
:alt: Documentation Status

Overview
--------

Hpsspy is a Python_ package for interacting with the HPSS_ tape storage
HPSSPy is a Python_ package for interacting with the HPSS_ tape storage
system at NERSC_. It is currently being developed on GitHub_.

.. _Python: http://python.org
Expand All @@ -16,13 +40,13 @@ system at NERSC_. It is currently being developed on GitHub_.
Requirements
------------

Hpsspy assumes that the HPSS utilities `hsi and htar`_ are installed. You may
HPSSPy assumes that the HPSS utilities `hsi and htar`_ are installed. You may
need a NERSC account to download and install these utilities.

.. _`hsi and htar`: https://www.nersc.gov/users/data-and-file-systems/hpss/storing-and-retrieving-data/software-downloads/

License
-------

Hpsspy is free software licensed under a 3-clause BSD-style license. For details see
HPSSPy is free software licensed under a 3-clause BSD-style license. For details see
the ``LICENSE.rst`` file.
19 changes: 19 additions & 0 deletions doc/api.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
==========
HPSSPy API
==========

.. automodule:: hpsspy
:members:

.. automodule:: hpsspy.os
:members:
:imported-members:

.. automodule:: hpsspy.os.path
:members:

.. automodule:: hpsspy.scan
:members:

.. automodule:: hpsspy.util
:members:
5 changes: 3 additions & 2 deletions doc/changes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,11 @@
Release Notes
=============

0.2.2 (unreleased)
0.3.0 (unreleased)
------------------

* No changes yet.
* General refresh of Python code, documentation, test suite.
* Command-line inputs are no longer rigidly restricted to SDSS or DESI.

0.2.1 (2015-04-22)
------------------
Expand Down
52 changes: 33 additions & 19 deletions doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@

import sys
import os
import hpsspy
# import hpsspy

# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
# documentation root, use os.path.abspath to make it absolute, like shown here.
#sys.path.insert(0, os.path.abspath('.'))
sys.path.insert(0, os.path.abspath('..'))

# -- General configuration ------------------------------------------------

Expand All @@ -31,16 +31,24 @@
# ones.
extensions = [
'sphinx.ext.autodoc',
'sphinx.ext.autosummary',
'sphinx.ext.doctest',
'sphinx.ext.intersphinx',
'sphinx.ext.todo',
'sphinx.ext.coverage',
'sphinx.ext.mathjax',
'sphinx.ext.viewcode',
'hpsspy.sphinx.ext.numpydoc'
'sphinx.ext.napoleon'
]

# Configuration for intersphinx, copied from astropy.
intersphinx_mapping = {
'python': ('http://docs.python.org/', None),
# 'python3': ('http://docs.python.org/3/', path.abspath(path.join(path.dirname(__file__), 'local/python3links.inv'))),
'numpy': ('http://docs.scipy.org/doc/numpy/', None),
'scipy': ('http://docs.scipy.org/doc/scipy/reference/', None),
'matplotlib': ('http://matplotlib.org/', None),
'astropy': ('http://docs.astropy.org/en/stable/', None),
'h5py': ('http://docs.h5py.org/en/latest/', None)
}

# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']

Expand All @@ -56,16 +64,19 @@
# General information about the project.
project = u'hpsspy'
author = 'Benjamin Alan Weaver'
copyright = u'2015, Benjamin Alan Weaver'
copyright = u'2014-2017, Benjamin Alan Weaver'

# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
# built documents.
#

__import__(project)
package = sys.modules[project]

# The short X.Y version.
version = hpsspy.__version__.split('-', 1)[0]
version = package.__version__.split('-', 1)[0]
# The full version, including alpha/beta/rc tags.
release = hpsspy.__version__
release = package.__version__

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand All @@ -86,7 +97,7 @@
#default_role = None

# If true, '()' will be appended to :func: etc. cross-reference text.
#add_function_parentheses = True
add_function_parentheses = True

# If true, the current module name will be prepended to all description
# unit titles (such as .. function::).
Expand All @@ -103,16 +114,23 @@
#modindex_common_prefix = []

# If true, keep warnings as "system message" paragraphs in the built documents.
#keep_warnings = False
keep_warnings = False

# Supress warnings about nonexistent documents.
numpydoc_show_class_members = False
# Include functions that begin with an underscore, e.g. _private().
napoleon_include_private_with_doc = True

# -- Options for HTML output ----------------------------------------------

# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
html_theme = 'default'
#html_theme = 'default'
#html_theme = 'haiku'
try:
import sphinx_rtd_theme
html_theme = 'sphinx_rtd_theme'
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
except ImportError:
pass

# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
Expand Down Expand Up @@ -270,7 +288,3 @@

# If true, do not generate a @detailmenu in the "Top" node's menu.
#texinfo_no_detailmenu = False


# Example configuration for intersphinx: refer to the Python standard library.
intersphinx_mapping = {'http://docs.python.org/': None}
Loading

0 comments on commit f73912b

Please sign in to comment.