Skip to content

Instantly share code, notes, and snippets.

@GantMan
Forked from skellock/settings.json5
Created January 16, 2018 19:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save GantMan/0fb618d4d6a8b156d75d73e16d50727a to your computer and use it in GitHub Desktop.
Save GantMan/0fb618d4d6a8b156d75d73e16d50727a to your computer and use it in GitHub Desktop.
Showing a subset of directories in vscode 🤦‍♀️
{
"files.exclude": {
// ## WHATS THE DEAL?
//
// VS Code doesn't support:
//
// * glob negation pattern (like globs usually have)
// * `false` values that can opt out
// * a `files.include`
// * support for auto excluding .gitignore
// * or any other seamingly sane way to do "not" patterns
//
// ## CREDIT
//
// https://github.com/Microsoft/vscode/issues/869#issuecomment-298878442
//
// ## EXAMPLE
//
// Hide everything except:
//
// * node_modules/react-n*
// * node_modules/reacto*
// * node_modules/ax*
// * node_modules/api*
//
/**/"**/node_modules/[^ra]*": true,
/* */"**/node_modules/r[^e]*": true,
/* */"**/node_modules/re[^a]*": true,
/* */"**/node_modules/rea[^c]*": true,
/* */"**/node_modules/reac[^t]*": true,
/* */"**/node_modules/react[^o-]*": true,
/* */"**/node_modules/react-[^n]*": true,
/* */"**/node_modules/a[^xp]*": true,
/* */"**/node_modules/ap[^i]*": true,
/**/"**/node_modules/react": true,
//
// ## INDENT MUCH?
//
// I added extra indentation to help illustrate the "tree" we're
// trying to build. With a little more effort, we could totally make
// a sailboat eh?
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment