You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
303 B
JavaScript
17 lines
303 B
JavaScript
const { platform, EOL } = require('os');
|
|
const { execSync } = require('child_process');
|
|
|
|
const list_dir = () => {
|
|
if(platform == 'linux') {
|
|
return execSync("ls -lA | awk '{print $9}'")
|
|
.toString()
|
|
.split(EOL);
|
|
}
|
|
|
|
}
|
|
|
|
const m = list_dir().forEach((l) => {
|
|
if(l == '.git')
|
|
console.log(true);
|
|
});
|