-
Notifications
You must be signed in to change notification settings - Fork 5
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
Added a CLI #38
Merged
Merged
Added a CLI #38
Changes from all commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
9c95d5e
Base CLI Added
quantum9Innovation 82522b4
Added CHANGELOG.md
quantum9Innovation 3837976
Changed Coverage Workflow to Track bin/epispot
quantum9Innovation 5713b38
Changed coverage.yml for Debugging
quantum9Innovation efffa62
Added Shell Testing Scripts
quantum9Innovation f2ddd1a
Allows for CI Testing on bin/
quantum9Innovation ca95791
workflow-debug1
quantum9Innovation 1e763db
Eliminated Coverage, Added Build Tests
quantum9Innovation 200f5d7
Installed CLI Requirements for Building
quantum9Innovation 73b216c
Update .github/workflows/build.yml
quantum9Innovation File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,7 @@ | ||
[run] | ||
source = epispot | ||
source = | ||
epispot | ||
bin | ||
|
||
[report] | ||
show_missing = True |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# Nightly Changelog | ||
@v2.1.1.2 | ||
___ | ||
|
||
- v2.1.1.2 | ||
- Added *very* basic epispot CLI functionality | ||
- See `bin/requirements.txt` for CLI requirements | ||
- Fire up a terminal and enter | ||
```shell | ||
$ epispot about | ||
``` | ||
- Added this changelog for nightly package |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
#!/usr/bin/env python | ||
|
||
"""Shell Initialization""" | ||
import pathlib | ||
import epispot | ||
|
||
__color__ = False | ||
|
||
try: | ||
import fire | ||
except: | ||
print("Please install Fire to use epispot's CLI") | ||
print('>>> pip install fire') | ||
|
||
try: | ||
__color__ = True | ||
import termcolor | ||
except: | ||
print('Color output will be suppressed. To use colors run') | ||
print('>>> pip install termcolor') | ||
|
||
|
||
class Shell(object): | ||
"""The base shell for epispot containing linking commands for Fire""" | ||
|
||
def __init__(self, color=False): | ||
"""Initialize the epispot shell""" | ||
|
||
self.color = color | ||
self.path = pathlib.Path(__file__).parent.absolute() | ||
self.version = 'shell-v0.1.0-alpha epispot-{0}'.format(epispot.__version__) | ||
|
||
def about(self): | ||
"""Basic information about the epispot CLI""" | ||
|
||
print('Epispot was invoked via the epispot CLI') | ||
print('Path: {0}'.format(self.path)) | ||
print('Version: {0}'.format(self.version)) | ||
print('Color output enabled (True/False): {0}'.format(self.color)) | ||
|
||
|
||
if __name__ == '__main__': | ||
fire.Fire(Shell( | ||
color=__color__ | ||
)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
epispot | ||
fire | ||
termcolor |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,2 @@ | ||
matplotlib | ||
numpy | ||
sphinx | ||
numpy |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why are you using a library like termcolor for terminal string styling? You can use the python built-in ANSI escape codes which are much more customizable, such as italics or underlined