FailedMathematician
FailedMathematician

Reputation: 467

shell script, where is directory of file created?

I have been a windows user and have just gotten into the unix (/ real) world.

In shell script

#!/bin/bash
FILE=/tmp/query-api-test-data.txt
echo "{ \"index\" : { \"_index\" : \"cdr_${DATE}\", \"_type\" : \"xdr\" } }" >> $FILE

My question is where in windows can i find this file?

Upvotes: 0

Views: 20

Answers (1)

Aracthor
Aracthor

Reputation: 5907

You wrote file localization at this line:

FILE=/tmp/query-api-test-data.txt

It means you can find the file here:

/tmp/query-api-test-data.txt

But as it is in /tmp folder, it is not supposed to be a file that you would use, so it may be deleted after your script.

Upvotes: 1

Related Questions