Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. 3rd Party Software
  4. [Solved] Qt + ODB --include-regex

[Solved] Qt + ODB --include-regex

Scheduled Pinned Locked Moved 3rd Party Software
3 Posts 2 Posters 1.7k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    diegofesanto
    wrote on last edited by
    #1

    Hi,

    In .pro file I'm try put this expression
    @--include-regex $$re_escape(%./include/entity/(.+)-odb.h%$1-odb.h%)@

    to change the include from ./include/entity/test-odb.h to test-odb.h, but doesn't work, it always changes to -odb.h.

    Someone know to help.

    Thank you

    P.S: Complete line in .pro file
    @ODB_FLAGS = --database pgsql --profile qt --generate-schema --generate-query --generate-session --std c++11 --hxx-suffix .h --schema-format embedded --include-prefix ./include/entity/ --include-regex $$re_escape(%./include/entity/(.+)-odb.h%$1-odb.h%)@

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi and welcome to devnet,

      Shouldn't your regex rather be:

      @%./include/entity/(.+)-odb.h%\1-odb.h%@

      ?

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0
      • D Offline
        D Offline
        diegofesanto
        wrote on last edited by
        #3

        [quote author="SGaist" date="1423093764"]Hi and welcome to devnet,

        Shouldn't your regex rather be:

        @%./include/entity/(.+)-odb.h%\1-odb.h%@

        ?[/quote]

        Hi SGaist thank you...

        I changed the regex following your example and now it's working.
        About the regex the error was in $, was only change that $ to this .
        Now my problem was solved I go to read a bit about perl regex.

        Thank you again.

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved