Add Support for Reading Source Text From Standard Input#43
Open
Add Support for Reading Source Text From Standard Input#43
Conversation
Implemented functionality to read source text from stdin, allowing users to specify input using '-' or '-.ext'. This implementation is kept rather simple, effectively reading input from stdin and writing it into a temporary file. This is done so that the path to the temporary file can be passed to the API of the rcnCount() function. This avoids the need to introduce another API function at this point, or to provide a quasi separate implementation of rcnCount() in the scount code. [CL]: Added support in scount for reading source input via stdin. [Issue#31] Signed-off-by: Phil Gaiser <phil.gaiser@raven-computing.com>
Signed-off-by: Phil Gaiser <phil.gaiser@raven-computing.com>
Signed-off-by: Phil Gaiser <phil.gaiser@raven-computing.com>
Signed-off-by: Phil Gaiser <phil.gaiser@raven-computing.com>
…s invalid. Signed-off-by: Phil Gaiser <phil.gaiser@raven-computing.com>
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Adds support in
scountto specify via the '-' argument that the input should not be read from a file but rather taken from standard input. By providing an explicit extension '-.ext', the user can further specify that the provided source input should be treated as source formatted in a specific format or programming language.