Skip to content
Snippets Groups Projects
Commit d4834c7f authored by Cédric Moreau's avatar Cédric Moreau
Browse files

[fix] `search [pattern]` command: only look for .json files

parent 14e12451
No related branches found
No related tags found
No related merge requests found
......@@ -156,7 +156,7 @@ module.exports = {
try {
const files: string[] = await new Promise((res, rej) => exec(`grep -r ${pattern} ${server.home}/${server.conf.currency} -l`, (err, stdout) => {
const files: string[] = await new Promise<string[]>((res, rej) => exec(`grep -r ${pattern} ${server.home}/${server.conf.currency} -l | grep .json`, (err, stdout) => {
if (err) return rej(err)
console.log(stdout)
res(stdout.split('\n').filter(l => l))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment