Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

165
Visualizações
pattern matching standards (eg .gitignore)

I've worked with a bunch of different tools that have the intention of searching a codebase for files of some type or another and then performing operations on files within. Test libs that find all the files that need to be executed for example. Or the prototypical example is git, which does all kinds of things with all the files in it's project directory.

Most of these products have an equivalent of .gitignore, which has a pattern matching system to make it relatively easy to define which files or subdirectories in a certain directory will be processed vs which would would not.

The pattern matching is simpler than regex (which I assume is good because regex would be overkill) and I'm guessing one of the advantages of the simpler pattern matcher is that it is faster? It makes sense that since every file or directory being crawled in the directory structure needs to be checked against every possible pattern match in the ignore file.

I have a TypeScript project where I want to do a similar type of processing of many files in a directory tree. To crawl the directories I'm currently using fdir https://github.com/thecodrr/fdir. The question is, is there a name for the .gitignore style pattern matching language? Is there libraries for Typescript or Javascript I can use to implement this pattern matching the the maximum possible performance?

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

https://www.npmjs.com/package/ignore seems to be a very common library for this. 48M weekly downloads, used by eslint so you're probably in good company.

about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda