0

I have my minecraft server.jar application that prints a log to the terminal. While I know you can log output from a specific shell by using the script command, that seems a bit heavy for my application. I want to scan each line of the shell and check if it's useful before grabbing it. What c++ functions are able to do this?

Even better, if I could start the program only when I've triggered my server.jar file that'd be really efficient.

Here is potentially relevant information on reading through a pipeline.

Ðаn
  • 10,934
  • 11
  • 59
  • 95
  • I would imagine you would just want to pipe the output to your program, and then read it from its stdin, i.e. something like `java -jar server.jar |./program` – vlumi Sep 01 '21 at 13:52

1 Answers1

0

Instead of reading through a pipeline. I have done some research on the spigot site and have discovered that it uses log4j as its logger. I can grab information via this and push it to a database using hikariCP/JBDC and take from there.