Zum Hauptinhalt springen
Echtzeit-Radar & Feeds
Alle RSS Feeds ➔
👥 Community & Social
Windows Tipps & SecurityGrafikkarte vor Überhitzung schützen: So geht’s(25.09.2026 um 08:00 Uhr)
••••••••••
Windows Tipps & SecurityGrafikkarte vor Überhitzung schützen: So geht’s(25.09.2026 um 08:00 Uhr)
••••••••••
Intelligence View
⚡ tsecurity.de Intelligence

Advice: CLI program defaults to writing a file, what if I want stdout?

I have a simple CLI program that runs calculations on inputs from a text file and produces another text file for output. (I hope this isn't self-promotion, I can remove the link if its borderline!) Unless directed otherwise, if you invoke…

0
↗ Quelle (reddit.com)
Reagiere als Erste:r — dein Feedback zählt!

I have a simple CLI program that runs calculations on inputs from a text file and produces another text file for output. (I hope this isn't self-promotion, I can remove the link if its borderline!)

Unless directed otherwise, if you invoke it with filename.nec, it writes the output to filename.out. You can supply multiple files on the input line, or even a glob, so the automatic-name makes sense.

But it is also possible you might want to run it to stdout. This would be the default behaviour for most unix CLI programs (is that true?) I know there are some programs that automatically go to files, like gzip and such, and I'd like to match "the most standard behaviour" for this sort of thing.

Right now I have a -o flag so you can -o someotherfilename.out, and I re-wired that to allow - so you can do onec -o - inputfile.nec and then it goes to stdout.

Is that "right"? Or is there something else that people would expect?

submitted by /u/maurymarkowitz
[link] [comments]
Ähnliche Beiträge
🔍 Verwandte News

Auch interessante Nachrichten Advice: CLI program defaults to writing a file, what if I want stdout?

Thematisch verwandte Begriffe: Advice, program, defaults, writing · 6 Treffer

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

💬 Kommentare werden geladen…
Zum Aktualisieren ziehen
ZERO-DAY CVE-2026-101018 | A vulnerability was determined in dayrui XunruiCMS up to 4.7.2. This is…
Advisory →
tsecurity.de Icon
Offline-Lesen, Eilmeldungen & 0ms Ladezeit

Installiere tsecurity.de direkt auf deinen Home-Bildschirm für das ultimative Vollbild-Magazinerlebnis ohne Browser-Leisten.

Nächster Beitrag