Giter Club home page Giter Club logo

Comments (9)

martinmoene avatar martinmoene commented on June 9, 2024 1

Thanks for asking @Jargon4072 .

I see that there's no such example.

Defining clue_LOG_EXPRESSION may allow you to setup writing to a file, see example 3 for using clue_LOG_EXPRESSION.

I'll try to think of and add an example later.

Hope this helps.

from clue.

martinmoene avatar martinmoene commented on June 9, 2024 1

@Jargon4072, Trying to add something like clue_LOG_TO_FILE. Please don't hold your breath :)

from clue.

martinmoene avatar martinmoene commented on June 9, 2024 1

@Jargon4072 , Added clue_LOG_TO_FILE, see example 5.

from clue.

martinmoene avatar martinmoene commented on June 9, 2024 1

Yeah i later realized i forgot to open the file for apppend. Will change that.

from clue.

martinmoene avatar martinmoene commented on June 9, 2024 1

I tried your method and I got the below errors: stray '\'...

Looks like in your shell the '\' should be omitted, like:

g++ -Wall -Wextra -Weffc++ -I.. -Dclue_LOG_TO_FILE="clue-log.txt" -o example5.exe example5.cpp && example5

from clue.

Jargon4072 avatar Jargon4072 commented on June 9, 2024

Thanks a lot! I can now log into a file! Thank you so much for your very fast reply and for adding this feature quickly :) I am now closing it!!

from clue.

Jargon4072 avatar Jargon4072 commented on June 9, 2024

Hi,
I tried your method and I got the below errors:
image

Also, I tried giving log file name via #define clue_LOG_TO_FILE "clue.txt" in example5.cpp it worked but it was not appending logs at the end of the file instead it replaced the existing lines in the file. How to make it to append new logs at the end instead of replacing exiting lines?

from clue.

Jargon4072 avatar Jargon4072 commented on June 9, 2024

Everything is working perfectly. Thanks!! Also, in the multithreaded environment this is working well so far. Thanks a lot!! :)

from clue.

martinmoene avatar martinmoene commented on June 9, 2024

Thanks for your question & feedback :)

from clue.

Related Issues (5)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.