From 3f229debf9f238966be3039b9bbaf1206702e700 Mon Sep 17 00:00:00 2001 From: Michael Hanke Date: Tue, 2 Oct 2018 17:27:28 +0200 Subject: [PATCH] Rename to datalad-revolution --- .gitignore | 26 +++++++++++++++++++ .travis.yml | 4 +-- README.md | 4 +-- .../__init__.py | 16 ++++++------ .../tests/test_register.py | 0 setup.py | 6 ++--- 6 files changed, 41 insertions(+), 15 deletions(-) create mode 100644 .gitignore rename {datalad_helloworld => datalad_revolution}/__init__.py (92%) rename {datalad_helloworld => datalad_revolution}/tests/test_register.py (100%) diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..1c96b71 --- /dev/null +++ b/.gitignore @@ -0,0 +1,26 @@ +.pybuild/ +datalad.build/ +/.idea +.coverage +/venv* +/cfgs +/dist +/fixtures +/diagrams +/build +/docs/build +/docs/source/generated +/docs/source/_extras/schema.json +/.tox +/repos +tmp +.noseids +*.egg-info +*.py[coe] +*.bak +.#* +.orig +.rej +.*.swp +.travis.yml.evil-bd +.asv diff --git a/.travis.yml b/.travis.yml index a4b5e7f..85ab305 100644 --- a/.travis.yml +++ b/.travis.yml @@ -23,8 +23,8 @@ env: - COVERAGE=coverage - DATALAD_DATASETS_TOPURL=http://datasets-tests.datalad.org matrix: - - DATALAD_REPO_DIRECT=yes - DATALAD_REPO_VERSION=5 + - DATALAD_REPO_VERSION=6 before_install: @@ -58,7 +58,7 @@ script: $NOSE_WRAPPER `which nosetests` $NOSE_OPTS -v -A "$NOSE_SELECTION_OP(integration or usecase or slow)" --with-doctest - --with-cov --cover-package datalad_helloworld + --with-cov --cover-package datalad_revolution --logging-level=INFO $TESTS_TO_PERFORM #- if [ ! "${DATALAD_LOG_LEVEL:-}" = 2 ]; then diff --git a/README.md b/README.md index 313c8f9..c5a0039 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # DataLad extension template -[![Travis tests status](https://secure.travis-ci.org/datalad/datalad-extension-template.png?branch=master)](https://travis-ci.org/datalad/datalad-extension-template) [![codecov.io](https://codecov.io/github/datalad/datalad-extension-template/coverage.svg?branch=master)](https://codecov.io/github/datalad/datalad-extension-template?branch=master) +[![Travis tests status](https://secure.travis-ci.org/datalad/datalad-revolution.png?branch=master)](https://travis-ci.org/datalad/datalad-revolution) [![codecov.io](https://codecov.io/github/datalad/datalad-revolution/coverage.svg?branch=master)](https://codecov.io/github/datalad/datalad-revolution?branch=master) This repository contains an extension template that can serve as a starting point for implementing a [DataLad](http://datalad.org) extension. An extension can @@ -21,5 +21,5 @@ DataLad will now expose a new command suite with `hello...` commands. To start implementing your own extension, fork this project and adjust as necessary. The comments in [setup.py](setup.py) and -[__init__.py](datalad_helloworld/__init__.py) illustrate the purpose of the various +[__init__.py](datalad_revolution/__init__.py) illustrate the purpose of the various aspects of a command implementation and the setup of an extension package. diff --git a/datalad_helloworld/__init__.py b/datalad_revolution/__init__.py similarity index 92% rename from datalad_helloworld/__init__.py rename to datalad_revolution/__init__.py index b86c6a3..5eedbc5 100644 --- a/datalad_helloworld/__init__.py +++ b/datalad_revolution/__init__.py @@ -19,18 +19,18 @@ # to be found by datalad command_suite = ( # description of the command suite, displayed in cmdline help - "Demo DataLad command suite", + "DataLad revolutionary command suite", [ # specification of a command, any number of commands can be defined ( # importable module that contains the command implementation - 'datalad_helloworld', + 'datalad_revolution', # name of the command class implementation in above module - 'HelloWorld', + 'RevolutionCommand', # optional name of the command in the cmdline API - 'hello-cmd', + 'rev-cmd', # optional name of the command in the Python API - 'hello_py' + 'rev_cmd' ), ] ) @@ -39,7 +39,7 @@ # decoration auto-generates standard help @build_doc # all commands must be derived from Interface -class HelloWorld(Interface): +class RevolutionCommand(Interface): # first docstring line is used a short description in the cmdline help # the rest is put in the verbose help and manpage """Short description of the command @@ -62,14 +62,14 @@ class HelloWorld(Interface): @staticmethod # decorator binds the command to the Dataset class as a method - @datasetmethod(name='hello') + @datasetmethod(name='rev_hello') # generic handling of command results (logging, rendering, filtering, ...) @eval_results # signature must match parameter list above # additional generic arguments are added by decorators def __call__(language='en'): if language == 'en': - msg = 'Hello!' + msg = 'Revolution!' elif language == 'de': msg = 'Tachchen!' else: diff --git a/datalad_helloworld/tests/test_register.py b/datalad_revolution/tests/test_register.py similarity index 100% rename from datalad_helloworld/tests/test_register.py rename to datalad_revolution/tests/test_register.py diff --git a/setup.py b/setup.py index f407e9b..2d803f1 100755 --- a/setup.py +++ b/setup.py @@ -5,7 +5,7 @@ setup( # basic project properties can be set arbitrarily - name="datalad_helloworld", + name="datalad_revolution", author="The DataLad Team and Contributors", author_email="team@datalad.org", version='0.1', @@ -16,7 +16,7 @@ # in general datalad will be a requirement, unless the datalad extension # aspect is an optional component of a larger project # disable for now as we currently need a Git snapshot (requirements.txt) - #'datalad', + 'datalad', ], entry_points = { # 'datalad.extensions' is THE entrypoint inspected by the datalad API builders @@ -24,7 +24,7 @@ # the label in front of '=' is the command suite label # the entrypoint can point to any symbol of any name, as long it is # valid datalad interface specification (see demo in this extensions - 'helloworld=datalad_helloworld:command_suite', + 'revolution=datalad_revolution:command_suite', ] }, )