Selecionar arquivos que Não contenham determinado texto

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • ccmancio
    Old Hand
    • May 2005
    • 235

    Selecionar arquivos que Não contenham determinado texto

    Tentei diversos itens como :
    ^((?!Mancio).)*$
    ^(?!Mancio).*$
    !(Mancio)
    (!Mancio)

    mas nada funciona
    Alguma dica ?
  • mdes
    Moderator
    • Apr 2008
    • 251

    #2
    Sessions Parameters > Other filters: Add a filter "Exclude the files Containing", and put Mancio in the following field.

    Google translation:
    Sessions Parameters > Other filters: Adicionar um filtro "Exclude the files Containing", e colocar Mancio no campo seguinte.

    Click image for larger version

Name:	BC4.png
Views:	1
Size:	17.3 KB
ID:	76249
    Last edited by mdes; 03-Sep-2014, 03:18 PM. Reason: Google translation added.
    Michel Dessaintes
    Modérateur du Forum Francophone & Traducteur Officiel de BC2/BC3/BC4 en Français

    Comment

    • ccmancio
      Old Hand
      • May 2005
      • 235

      #3
      Eu estou usando BC3. e não tem esta opção

      Comment

      • Aaron
        Team Scooter
        • Oct 2007
        • 15941

        #4
        The newest release of BC3 (3.3.12) does have this option in the Folder Compare, Session Settings, Other Filters tab.

        translate.google.com
        A mais nova versão do BC3 (3.3.12) tem essa opção na pasta Compare, Configurações da Sessão, guia outros filtros.
        Aaron P Scooter Software

        Comment

        • ccmancio
          Old Hand
          • May 2005
          • 235

          #5
          Eu estou com a versão 3.3.12 e não tem esta opção, veja anexos.
          Attached Files

          Comment

          • mdes
            Moderator
            • Apr 2008
            • 251

            #6
            "Mancio" should be found exactly 0 times:
            Click image for larger version

Name:	BC3.png
Views:	1
Size:	13.7 KB
ID:	76254
            Last edited by mdes; 05-Sep-2014, 06:55 AM.
            Michel Dessaintes
            Modérateur du Forum Francophone & Traducteur Officiel de BC2/BC3/BC4 en Français

            Comment

            • ccmancio
              Old Hand
              • May 2005
              • 235

              #7
              Acredito que no lugar de "body" deveria colocar "Mancio", certo Michel ? Mas não funciona, não aparece qualquer arquivo, tanto os que contem Mancio, como os que não contem Mancio.

              Comment

              • mdes
                Moderator
                • Apr 2008
                • 251

                #8
                1. Exact: That's because I tested with "body".

                2. Exact also: it doesn't seem to work.

                I created 2 files: the first with once "Mancio", and the second with twice "Mancio".
                The RegExp "(Mancio){1}" gives the 2 files, while "(Mancio){2}" gives none

                -----Google translation-----
                1. Exatas: Isso é porque eu testei com o "corpo".

                2. Exact também: ele não parece funcionar.

                Eu criei dois arquivos: o primeiro com uma vez "Mancio", eo segundo com duas vezes "Mancio".
                O RegExp "(Mancio){1}" dá os 2 arquivos, enquanto "(Mancio){2}" dá nenhum
                Last edited by mdes; 05-Sep-2014, 07:32 AM.
                Michel Dessaintes
                Modérateur du Forum Francophone & Traducteur Officiel de BC2/BC3/BC4 en Français

                Comment

                • mdes
                  Moderator
                  • Apr 2008
                  • 251

                  #9
                  Regular expression to match string not containing a word

                  Use the following regular expression: ^((?!Mancio).)*$

                  Source: http://stackoverflow.com/questions/4...taining-a-word
                  See explanation at http://stackoverflow.com/a/23583655
                  More informations: http://www.regular-expressions.info/refadv.html

                  -----Google translation-----

                  Use a seguinte expressão regular: ^((?!Mancio).)*$
                  Origem: http://stackoverflow.com/questions/4...taining-a-word
                  Veja a explicação em http://stackoverflow.com/a/23583655
                  Mais informações: http://www.regular-expressions.info/refadv.html
                  Last edited by mdes; 05-Sep-2014, 08:07 AM.
                  Michel Dessaintes
                  Modérateur du Forum Francophone & Traducteur Officiel de BC2/BC3/BC4 en Français

                  Comment

                  • Aaron
                    Team Scooter
                    • Oct 2007
                    • 15941

                    #10
                    Excellent research, mdes!

                    We also added a "Excludes" filter for text content to BC4, but this should work for BC3.
                    Aaron P Scooter Software

                    Comment

                    • ccmancio
                      Old Hand
                      • May 2005
                      • 235

                      #11
                      ainda não funciona

                      Eu já tinha tentado esta opção, e não funcionou, veja nas mensagens anteriores
                      O que é que esta errado ?
                      Anexo o resultado do BC3
                      Attached Files

                      Comment

                      • mdes
                        Moderator
                        • Apr 2008
                        • 251

                        #12
                        Very strange, I don't have this problem!

                        My files contain:
                        Originally posted by BC3_None.txt
                        xxx
                        Originally posted by BC3_Once.txt
                        xxx Mancio xxx
                        Originally posted by BC3_Twice.txt
                        xxx Mancio Mancio xxx
                        and the result is:
                        Click image for larger version

Name:	BC3a.png
Views:	1
Size:	81.2 KB
ID:	76256
                        So only the files without "Mancio" are displayed. Those containing "Mancio" are filtered, i.e. not displayed (except with the button "Suppress filter" / Barred glasses, as I did on my screen shot).

                        -----Google translation-----
                        Muito estranho, eu não tenho esse problema!

                        Meus arquivos contêm:
                        Originally posted by BC3_None.txt
                        xxx
                        Originally posted by BC3_Once.txt
                        xxx Mancio xxx
                        Originally posted by BC3_Twice.txt
                        xxx Mancio Mancio xxx
                        e o resultado é:
                        [...]
                        Assim, somente os arquivos sem "Mancio" são exibidos. Aqueles que contêm "Mancio" são filtradas, ou seja, não é exibido (exceto com o botão "Suprimir filtro" / óculos barrado, como eu fiz na minha captura de tela).
                        Michel Dessaintes
                        Modérateur du Forum Francophone & Traducteur Officiel de BC2/BC3/BC4 en Français

                        Comment

                        • Aaron
                          Team Scooter
                          • Oct 2007
                          • 15941

                          #13
                          It is hard to see from that screenshot, but it almost looks like you have:
                          M a n c i o, rather than Mancio? These would be two different phrases.

                          If you are still having trouble, I might recommend trying the trial of BC4 and using our built-in Exclude and Include support for text content filters.
                          Aaron P Scooter Software

                          Comment

                          • ccmancio
                            Old Hand
                            • May 2005
                            • 235

                            #14
                            Realmente é muito estranho, criei um arquivo com duas linhas,
                            A primeira tem um caracter em branco(espaço) e a segunda a palavra Mancio.
                            Não funciona, faça o teste.

                            Se eu retiro o espaço , ai funciona, estou achando que ele só funciona se a palavra Mancio esta na primeira linha do arquivo ou se todas asa linhas anteriores estão sem conteudo, não sei ao certo porque não domino expressões regulares

                            Comment

                            • mdes
                              Moderator
                              • Apr 2008
                              • 251

                              #15
                              I agree: this does not work if "Mancio" is on a second line (I didn't test other cases).
                              Any other solution? I give up .
                              I agree with Aaron's solution to go to Beyond Compare v4 .

                              -----Google translation-----
                              Concordo: isso não funciona se "Mancio" está em uma segunda linha (eu não testar outros casos).
                              Qualquer outra solução? Desisto.
                              Concordo com a solução de Aaron para ir para Beyond Compare v4.
                              Michel Dessaintes
                              Modérateur du Forum Francophone & Traducteur Officiel de BC2/BC3/BC4 en Français

                              Comment

                              Working...