Questions tagged [output]

The externally observable consequences of calling a program on some input

The output of a program is the set of externally observable consequences of running a program on the given input.

A program's output can be manifested in several forms:

  1. What is printed to and/or
  2. What is written to an external file
  3. What changes are made to the inputs, which are then used in other functions or programs
9797 questions
18
votes
1 answer

ffmpeg command line write output to a text file

I'm using this script for shot detection in ffmpeg. ffprobe -show_frames -of compact=p=0 -f lavfi "movie=test.mp4,select=gt(scene\,0.3)" I need to write the output into a text file in order to read the output from a c program. How can I do this?…
Asanka sanjaya
  • 1,461
  • 3
  • 17
  • 35
18
votes
3 answers

Gradle: task's standardOutput to file and terminal simultaneously

I want to change standardOutput of one build task to file, because it will be parsed later by another task. But also, I would like to have simultaneously output in the terminal to see what's going on in the build. This is how I changed output of the…
Artem Zinnatullin
  • 4,305
  • 1
  • 29
  • 43
18
votes
8 answers

No output from PHP interactive on Windows

I'm running php interactively from xampp (5.4.7) on my Win 7 machine and cannot get any output from the window. I searched around various solutions and nothing so far has worked. Here's a sample: C:\xampp>php -v PHP 5.4.7 (cli) (built: Sep…
BaliDave
  • 141
  • 1
  • 1
  • 7
18
votes
2 answers

Recreate original PHP array from print_r output

Let's say I have this output from some source where I don't have access to the original PHP created array: Array ( [products] => Array ( [name] => Arduino Nano Version 3.0 mit ATMEGA328P [id] => 10005 ) …
Dan
  • 3,755
  • 4
  • 27
  • 38
18
votes
1 answer

Redirect stdout and stderr to the same file and restore it

I am redirecting the output of stderr and stdout of my c program to two files and then restoring the original stdout and stderr: int sout = dup(fileno(stdout)); freopen("test.txt","w",stdout); int serr =…
unlimited101
  • 3,653
  • 4
  • 22
  • 41
17
votes
4 answers

How to convert Pulumi Output to string?

I am dealing with creating AWS API Gateway. I am trying to create CloudWatch Log group and name it API-Gateway-Execution-Logs_${restApiId}/${stageName}. I have no problem in Rest API creation. My issue is in converting restApi.id which is of type…
Tigran Sahakyan
  • 363
  • 1
  • 5
  • 10
17
votes
4 answers

How to write files to current directory instead of bazel-out

I have the following directory structure: my_dir | --> src | | | --> foo.cc | --> BUILD | --> WORKSPACE | --> bazel-out/ (symlink) | | ... src/BUILD contains the following code: cc_binary( name = "foo", srcs =…
Ani Kristo
  • 335
  • 1
  • 2
  • 9
17
votes
6 answers

Jenkins console output has these strange characters from grunt command [31m[[39m...

I'm running a grunt-contrib-jshint command using jenkins and the console output is contains text like: [31m[[39m[33mL425[39m[31m:[39m[33mC29[39m[31m][39m [33mExpected a conditional expression and instead saw an assignment.[39m Any ideas why? and…
James Da Costa
  • 215
  • 1
  • 2
  • 7
17
votes
2 answers

Difference between JspWriter and PrintWriter in Java EE?

For all you "duplicate" fanatics, there is a similar question on SO right here. The difference is that I paint a vivid example that I can not understand the output of. The documentation for JspWriter and PrintWriter says there are two differences:…
Martin Andersson
  • 18,072
  • 9
  • 87
  • 115
16
votes
3 answers

Java audio visualizer- How to capture real-time sound output to speaker?

tl;dr For future readers, recording real-time audio is not possible (for now) with Java or C#. Use C++, as it provides a plethora of audio api's. My goal is to get the current sound played on a Windows machine, and analyze the sound much like a…
Eric
  • 444
  • 7
  • 19
16
votes
1 answer

How to get the output of a spawned child_process in Node.JS?

First of all, I'm a complete noob and started using Node.JS yesterday (it was also my first time using Linux in years) so please be nice and explicit I'm currently making a Node.JS program which has to, among other things, launch shell commands…
Runj
  • 185
  • 1
  • 2
  • 11
16
votes
5 answers

How to save output from python like tsv

I am using biopython package and I would like to save result like tsv file. This output from print to tsv. for record in SeqIO.parse("/home/fil/Desktop/420_2_03_074.fastq", "fastq"): print ("%s %s %s" % (record.id,record.seq,…
Vonton
  • 2,872
  • 4
  • 20
  • 27
16
votes
6 answers

How to print variable inside quotation marks?

I would like to print a variable within quotation marks. I want to print out "variable" I have tried a lot, what worked was: print('"', variable, '"') but then I have two spaces in the output: " variable " How can I print something within a pair…
Heiko
  • 329
  • 1
  • 2
  • 7
16
votes
14 answers

Eclipse Console not showing output

I have written a simple class having an SOP statement for "Hello World". But the Eclipse console is not showing output. I then wrote the same program in a previously created project and it worked fine. I am opening the Console as given…
user3497430
  • 161
  • 1
  • 1
  • 4
16
votes
4 answers

How do I write to a YAML file using SnakeYaml?

Consider the following code: public static void dumpObjectToYaml(String key, Object O, String path) throws IOException { Map data = new HashMap<>(); data.put(key, O); File F = new File(path); F.mkdirs(); …
Jonas Bartkowski
  • 357
  • 1
  • 6
  • 15