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

Feature/commands #2

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

danieleborsaro
Copy link

No description provided.

@danieleborsaro
Copy link
Author

This pull request introduces a set of functions that allow to execute subcommands while:

  1. produce a consistent output
  2. use the 'pretend' option
  3. control the subcommand output
  4. log and check subcommand execution with colourised (tags) output

This should mainly avoid chasing subcommands and manually add checks for std_DEBUG and std_PRETEND cases, all the while prettifying the output.

I have enclosed execution tags in square brackets to better visually distinguish control from subcommand outputs.

@@ -0,0 +1,65 @@
#!/bin/bash

# Copyright 2013-2016 Stuart Shelton
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should really have your copyright, not mine!


# This function may be overridden
#
# Wrapper to evalRes(), for backward compatibility
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With what?! ;)

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With something I did not port here from my own version of stdlib.sh :P
It's called: transcendental or astral compatibility because the function transcendentally refers to another function that lives in a non-sourced file :P

@srcshelton
Copy link
Owner

srcshelton commented May 27, 2016

I've made some notes inline in the changes - could you also confirm that the updated script passes ShellCheck's tests?

Also, please s/color/colour/gi ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants