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

Unable to pipe data on Windows #64

Closed
vladdeSV opened this issue Apr 25, 2021 · 8 comments
Closed

Unable to pipe data on Windows #64

vladdeSV opened this issue Apr 25, 2021 · 8 comments
Labels
BUG Something isn’t working

Comments

@vladdeSV
Copy link
Contributor

vladdeSV commented Apr 25, 2021

I am attempting to pipe output to klog.exe on Windows, version v2.2 [0bb0d83].

In this example I receive the following error:

$ cat .\time.klg | .\klog.exe total
Error: No input given
Please do one of the following:
    a) pass one or multiple file names as argument
    b) pipe file contents via stdin
    c) specify a bookmark to read from by default

This was attempted using PowerShell 7 (Preview) and Git for Windows (bash) respectively.

@vladdeSV
Copy link
Contributor Author

Just to be sure, in Git for Windows (bash) I ran the following command

$ cat ./time.klg | vim -

, which successfully piped stdin to vim.

Screenshot 2021-04-26 011230

@vladdeSV
Copy link
Contributor Author

vladdeSV commented Apr 25, 2021

Edit: Forgot to add klog version v2.2 [0bb0d83]. (i am sick and very tired)

@vladdeSV vladdeSV changed the title Unable to pipe output on Windows Unable to pipe data on Windows Apr 25, 2021
@vladdeSV
Copy link
Contributor Author

I also attempted this using pure cmd.exe (without using Windows Terminal) but received the same error

C:\Users\vladde>echo "2021-04-26" | .\klog.exe total
Error: No input given
Please do one of the following:
    a) pass one or multiple file names as argument
    b) pipe file contents via stdin
    c) specify a bookmark to read from by default

C:\Users\vladde>

@jotaen
Copy link
Owner

jotaen commented Apr 26, 2021

Thanks for reporting, I can reproduce this.

@jotaen jotaen added the BUG Something isn’t working label Apr 26, 2021
@jotaen jotaen closed this as completed in 633ac38 Apr 27, 2021
@vladdeSV
Copy link
Contributor Author

vladdeSV commented Apr 27, 2021

I still experience this issue, even after compiling newest version.

PS C:\Users\vladde> klog version
Command line tool: v2.2  [0bb0d83]
File format: version 1 (RFC)

Checking for newer version...
You already have the latest version!


PS C:\Users\vladde> echo 2020-01-01 | klog json
Error: No input given
Please do one of the following:
    a) pass one or multiple file names as argument
    b) pipe file contents via stdin
    c) specify a bookmark to read from by default
PS C:\Users\vladde>

Tested with PowerShell, Git for Windows (bash), and pure cmd.exe on Windows 10 Pro (19042.928).

@vladdeSV
Copy link
Contributor Author

If I can help with testing and so forth, tell me and I'll do my best to help out.

@jotaen
Copy link
Owner

jotaen commented Apr 28, 2021

Are you certain you have run the compiled binary and not your globally installed one? Because for the self-compiled binary the version output says Command line tool: v?.? [???????] (unless you configure the build flags manually to set these values explicitly).

@vladdeSV
Copy link
Contributor Author

You are completely right. I did not properly update my binary.

Works perfectly now 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
BUG Something isn’t working
Projects
None yet
Development

No branches or pull requests

2 participants