Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

repo: mv ./src/punx ./punx #141

Merged
merged 5 commits into from
Oct 29, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
4 changes: 2 additions & 2 deletions .coveragerc
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,6 @@ exclude_lines =
[run]
omit =
versioneer.py
src/punx/_version.py
src/punx/github_handler.py
punx/_version.py
punx/github_handler.py
tests/github_handler_test.py
4 changes: 2 additions & 2 deletions .flake8
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ exclude =
dist,
versioneer.py,
docs/source,
src/punx/_version.py,
src/punx/ignore_now,
punx/_version.py,
punx/ignore_now,
tests/ignore_now,
ideas

Expand Down
2 changes: 1 addition & 1 deletion .gitattributes
Original file line number Diff line number Diff line change
@@ -1 +1 @@
src/punx/_version.py export-subst
punx/_version.py export-subst
9 changes: 3 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,13 +1,10 @@
*.py[cod]

# local creds for authenticated access
src/punx/__github_creds__.txt
punx/__github_creds__.txt

# local NXDL source cache (to be packaged with sdist)
#src/punx/cache/*

# eclipse/PyDev
.pydevproject
#punx/cache/*

# C extensions
*.so
Expand Down Expand Up @@ -48,7 +45,7 @@ tests/__pycache__
.mr.developer.cfg
/.settings
/.idea
/src/punx/data/local
/punx/data/local

# Microsoft VS Code editor
.vscode/
8 changes: 4 additions & 4 deletions .landscape.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@ requirements:
- coveralls
ignore-paths:
- docs
- src/punx/cache
- src/punx/data
- src/punx/ignore_now
- punx/cache
- punx/data
- punx/ignore_now
- versioneer.py
- src/punx/_version.py
- punx/_version.py
- install_NXDL_file_sets.py
- _installer.py
ignore-patterns:
Expand Down
2 changes: 1 addition & 1 deletion CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Production
Development
***********

:0.2.6: 2021-*-tba -- drop support for python<3.6
:0.2.6: 2021--tba -- drop support for python<3.6
:0.2.5: 2020-06-29 -- bug fix and up to date
:0.2.0: 2018-07-02 -- first tag after major refactor (#72, #105)
:0.1.9: 2017-07-09 -- last tag before major refactor (#72), no changes here since 2017-03-31
Expand Down
14 changes: 7 additions & 7 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
include README.rst
include src/punx/LICENSE.txt
include src/punx/cache/*
include src/punx/cache/*/__github_info__.json
include src/punx/cache/*/*.xsd
include src/punx/cache/*/*/*.xml
include src/punx/cache/*/*/*.xsl
include src/punx/_version.py
include punx/LICENSE.txt
include punx/cache/*
include punx/cache/*/__github_info__.json
include punx/cache/*/*.xsd
include punx/cache/*/*/*.xml
include punx/cache/*/*/*.xsl
include punx/_version.py
include versioneer.py
14 changes: 7 additions & 7 deletions _starter_.py
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
#!/usr/bin/env python

import sys, os
sys.path.insert(0, os.path.abspath(os.path.join(os.path.dirname(__file__), 'src')))
sys.path.insert(0, os.path.abspath(os.path.dirname(__file__)))

# developer use
# if len(sys.argv) == 1:
# sys.argv.append("demo")
# sys.argv.append("conf")
# sys.argv.append("valid")
# sys.argv.append("src/punx/data/33837rear_1D_1.75_16.5_NXcanSAS_v3.h5")
# sys.argv.append("punx/data/33837rear_1D_1.75_16.5_NXcanSAS_v3.h5")
# # sys.argv.append("C:/Users/Pete/Downloads/1998spheres.h5")
# # sys.argv.append("src/punx/cache/v3.3/applications/NXcanSAS.nxdl.xml")
# # sys.argv.append("punx/cache/v3.3/applications/NXcanSAS.nxdl.xml")
# sys.argv.append("tree")
# sys.argv.append("src/punx/data/gov_5.h5")
# # sys.argv.append("src/punx/data/compression.h5")
# # sys.argv.append("src/punx/data/writer_1_3.hdf5")
# # sys.argv.append("src/punx/data/prj_test.nexus.hdf5")
# sys.argv.append("punx/data/gov_5.h5")
# # sys.argv.append("punx/data/compression.h5")
# # sys.argv.append("punx/data/writer_1_3.hdf5")
# # sys.argv.append("punx/data/prj_test.nexus.hdf5")


from punx import main
Expand Down
4 changes: 2 additions & 2 deletions check_data.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
# file: check_data.sh
# test that punx program can process all the files in the data directory

DATA_DIR=src/punx/data
DATA_DIR=punx/data

for f in `ls -1 ${DATA_DIR}`; do
echo src/punx/data/$f
echo punx/data/$f
./_starter_.py tree ${DATA_DIR}/$f
./_starter_.py validate ${DATA_DIR}/$f
done
2 changes: 1 addition & 1 deletion docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
# 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(os.path.join('..', '..', 'src')))
sys.path.insert(0, os.path.abspath(os.path.join('..', '..')))
import punx

# -- General configuration ------------------------------------------------
Expand Down
7 changes: 4 additions & 3 deletions docs/source/configuration.rst
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
.. _config:

.. index:: configuration

User interface: subcommand: **configuration**
Expand Down Expand Up @@ -38,14 +39,14 @@ revisions by the developers on that date).

An NXDL file set is *referenced* by one of the GitHub identifiers:

========= ========== ==========================================
========== ========== ==========================================
identifier example description
========= ========== ==========================================
========== ========== ==========================================
commit 9eab SHA-1 hash tag [#]_ that identifies a specific commit to the repository
branch master name of a branch [#]_ in the repository
tag Schema-3.4 name of a tag [#]_ in the repository
release v2018.5 name of a repository release [#]_
========= ========== ==========================================
========== ========== ==========================================

.. [#] commit (hash): A commit is a snapshot of the GitHub repository.
A SHA-1 hash code is the unique identifier of a commit.
Expand Down
2 changes: 1 addition & 1 deletion docs/source/license.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
License
=======

.. literalinclude:: ../../src/punx/LICENSE.txt
.. literalinclude:: ../../punx/LICENSE.txt
:language: text
2 changes: 1 addition & 1 deletion docs/source/overview.rst
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ Subcommands
.. toctree::
:hidden:

config
configuration
demo
hierarchy
tree
Expand Down
2 changes: 1 addition & 1 deletion docs/source/tree.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
.. index:: tree
.. _structure:
.. _tree:
.. index:: tree

User interface: subcommand: **tree**
####################################
Expand Down
18 changes: 9 additions & 9 deletions docs/source/update.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
.. _update:
.. index:: update
.. _update:

User interface: subcommand: **update**
######################################
Expand Down Expand Up @@ -32,7 +32,7 @@ when the source cache needed to be updated:
INFO: git iso8601: 2016-06-17T18:05:28Z
INFO: updating NeXus definitions files
INFO: download: https://github.com/nexusformat/definitions/archive/master.zip
INFO: extract ZIP to: C:/Users/Pete/Documents/eclipse/punx/src/punx/cache
INFO: extract ZIP to: C:/Users/Pete/Documents/eclipse/punx/punx/cache


.. rubric:: command line help
Expand Down Expand Up @@ -65,33 +65,33 @@ GitHub API rate limit exceeded
A common problem happens when updating the NXDL definitions from GitHub.
Here's what it looks like::

$ python ./src/punx/main.py update --force
$ python ./punx/main.py update --force

('INFO:', 'get repo info: https://api.github.com/repos/nexusformat/definitions/commits')

Traceback (most recent call last):

File "./src/punx/main.py", line 416, in <module>
File "./punx/main.py", line 416, in <module>

main()

File "./src/punx/main.py", line 412, in main
File "./punx/main.py", line 412, in main

args.func(args)

File "./src/punx/main.py", line 170, in func_update
File "./punx/main.py", line 170, in func_update

cache.update_NXDL_Cache(force_update=args.force)

File "/home/travis/build/prjemian/punx/src/punx/cache.py", line 257, in update_NXDL_Cache
File "/home/travis/build/prjemian/punx/punx/cache.py", line 257, in update_NXDL_Cache

info = __get_github_info__() # check with GitHub first

File "/home/travis/build/prjemian/punx/src/punx/cache.py", line 246, in __get_github_info__
File "/home/travis/build/prjemian/punx/punx/cache.py", line 246, in __get_github_info__

punx.GITHUB_NXDL_REPOSITORY)

File "/home/travis/build/prjemian/punx/src/punx/cache.py", line 228, in githubMasterInfo
File "/home/travis/build/prjemian/punx/punx/cache.py", line 228, in githubMasterInfo

raise punx.CannotUpdateFromGithubNow(msg)

Expand Down
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion src/punx/_version.py → punx/_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ def get_config():
cfg.style = "pep440"
cfg.tag_prefix = ""
cfg.parentdir_prefix = "punx-"
cfg.versionfile_source = "src/punx/_version.py"
cfg.versionfile_source = "punx/_version.py"
cfg.verbose = False
return cfg

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading