8 lines
175 B
JavaScript
8 lines
175 B
JavaScript
const shell = require('shelljs');
|
|
const fs = require('fs');
|
|
const DIR = '/tmp/x';
|
|
shell.find(DIR)
|
|
.filter((path) => fs.lstatSync(path).isFile())
|
|
.forEach((file) => {
|
|
|
|
}); |