Skip to main content

BuildStatus

Glint is a micro framework for command line applications, it creates the needed parameters that should be passed to the application based on the function signatures that it is supplied.

Inspiration

The inspiration for Glint came from wanting to have a command driven cli app similar to how git works which I was unable to replicate with argparse.

Requirements

Glint requires Python 3.3 or higher to run, it has no other dependencies outside of the python core library.

Installation

The easiest way to install Glint is to use pip and run:

pip install glint

Otherwise download the Glint source code extract it and from the root directory run:

python ./setup.py install

Usage

All usage documentation for Glint can be found over at read the docs.

Future Plans

If you want to see what’s coming up in the near future for Glint go visit the huboard for the project.

Contributing

The source for Glint can be found over at Github, if you want to contribute that would be a good place to start. If you are wanting to report a bug all of that is kept at github as well in the issue tracker, the issues are also used to track upcoming work on Glint though features/issues that will be worked on before the next release can be more easily visualised over at huboard. If you want to keep a track of the status of the bleeding edge then you’ll able to see the current state at Travis.

Submitting changes

You’ve downloaded/cloned Glint and made some changes you’d like to have merged in, firstly awesome thanks hugely! There are a couple of guidelines around submitting changes:

  • Changes will only be accepted via pull requests on github.

  • Any code changes should have some unit tests, if it’s a fix for a bug it won’t be accepted unless it has tests.

  • Again with any code changes if your pull request breaks the build it won’t be accepted.

Running the tests

While Glint doesn’t have any dependencies outside of the python core library you will need to install nose to run the tests. Once that is installed you have two options for running the test you can run either:

nostests

or

python ./setup.py test

Change Log

v0.2.0

  • Updated the argument parsing to allow optional arguments in the format of <prefix><name>=<value>

  • Updated the argument parsing to replace - characters with _ when parsing positional arguments and flags.

v0.1.0

  • Running a method based on the first argument supplied.

  • Running a ‘default’ method when no arguments are supplied.

  • Parsing of positional arguments based on method signature.

  • Parsing of optional arguments based on method signature.

  • Parsing of flags based on method signature.

  • Printing of dynamically generated help screen based on the commands that had been set up.

  • Printing of dynamically generated help screen for a particular command based on the method signature supplied to that command.

License

Glint is available under the MIT license which is as follows:

Copyright © 2013 Michael Lowen

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Metadata

Release files for Glint 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for Glint 0.2.0
File Size Uploaded
Glint-0.2.0.zip 10.0 kB Details

Release files / Glint-0.2.0.zip

Download URL Glint-0.2.0.zip
Size 10.0 kB
Tags Source
SHA-256 checksum
How to use checksums
d249e5606231af9612c71158ae8e3a7ca0933d3a6cb597096d61338f1aa3a0a2
BLAKE2b-256 checksum
How to use checksums
1e58286b5ce2a301d654f07a475d86e85ea1897df3c0347637038de52e31027b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

0.2.0 This release

1 release file

0.1.0

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page