mirror of
https://github.com/fooflington/selfdefined.git
synced 2025-06-10 21:01:41 +00:00
update
This commit is contained in:
30
node_modules/junk/index.js
generated
vendored
Normal file
30
node_modules/junk/index.js
generated
vendored
Normal file
@ -0,0 +1,30 @@
|
||||
'use strict';
|
||||
|
||||
// // All
|
||||
// /^npm-debug\.log$/, // npm error log
|
||||
// /^\..*\.swp$/, // vim state
|
||||
// // macOS
|
||||
// /^\.DS_Store$/, // stores custom folder attributes
|
||||
// /^\.AppleDouble$/, // stores additional file resources
|
||||
// /^\.LSOverride$/, // contains the absolute path to the app to be used
|
||||
// /^Icon\r$/, // custom Finder icon: http://superuser.com/questions/298785/icon-file-on-os-x-desktop
|
||||
// /^\._.*/, // thumbnail
|
||||
// /^\.Spotlight-V100$/, // file that might appear on external disk
|
||||
// /\.Trashes/, // file that might appear on external disk
|
||||
// /^__MACOSX$/, // resource fork
|
||||
// // Linux
|
||||
// /~$/, // backup file
|
||||
// // Windows
|
||||
// /^Thumbs\.db$/, // image file cache
|
||||
// /^ehthumbs\.db$/, // folder config file
|
||||
// /^Desktop\.ini$/ // stores custom folder attributes
|
||||
|
||||
exports.re = /^npm-debug\.log$|^\..*\.swp$|^\.DS_Store$|^\.AppleDouble$|^\.LSOverride$|^Icon\r$|^\._.*|^\.Spotlight-V100$|\.Trashes|^__MACOSX$|~$|^Thumbs\.db$|^ehthumbs\.db$|^Desktop\.ini$/;
|
||||
|
||||
exports.is = function (filename) {
|
||||
return exports.re.test(filename);
|
||||
};
|
||||
|
||||
exports.not = exports.isnt = function (filename) {
|
||||
return !exports.is(filename);
|
||||
};
|
21
node_modules/junk/license
generated
vendored
Normal file
21
node_modules/junk/license
generated
vendored
Normal file
@ -0,0 +1,21 @@
|
||||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com)
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in
|
||||
all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
THE SOFTWARE.
|
72
node_modules/junk/package.json
generated
vendored
Normal file
72
node_modules/junk/package.json
generated
vendored
Normal file
@ -0,0 +1,72 @@
|
||||
{
|
||||
"_args": [
|
||||
[
|
||||
"junk@1.0.3",
|
||||
"/Users/tatiana/selfdefined"
|
||||
]
|
||||
],
|
||||
"_from": "junk@1.0.3",
|
||||
"_id": "junk@1.0.3",
|
||||
"_inBundle": false,
|
||||
"_integrity": "sha1-h75jSIZJy9ym9Tqzm+yczSNH9ZI=",
|
||||
"_location": "/junk",
|
||||
"_phantomChildren": {},
|
||||
"_requested": {
|
||||
"type": "version",
|
||||
"registry": true,
|
||||
"raw": "junk@1.0.3",
|
||||
"name": "junk",
|
||||
"escapedName": "junk",
|
||||
"rawSpec": "1.0.3",
|
||||
"saveSpec": null,
|
||||
"fetchSpec": "1.0.3"
|
||||
},
|
||||
"_requiredBy": [
|
||||
"/recursive-copy"
|
||||
],
|
||||
"_resolved": "https://registry.npmjs.org/junk/-/junk-1.0.3.tgz",
|
||||
"_spec": "1.0.3",
|
||||
"_where": "/Users/tatiana/selfdefined",
|
||||
"author": {
|
||||
"name": "Sindre Sorhus",
|
||||
"email": "sindresorhus@gmail.com",
|
||||
"url": "sindresorhus.com"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/sindresorhus/junk/issues"
|
||||
},
|
||||
"description": "Filter out OS junk files like .DS_Store and Thumbs.db",
|
||||
"devDependencies": {
|
||||
"ava": "*",
|
||||
"xo": "*"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=0.10.0"
|
||||
},
|
||||
"files": [
|
||||
"index.js"
|
||||
],
|
||||
"homepage": "https://github.com/sindresorhus/junk#readme",
|
||||
"keywords": [
|
||||
"junk",
|
||||
"trash",
|
||||
"garbage",
|
||||
"files",
|
||||
"os",
|
||||
"ignore",
|
||||
"exclude",
|
||||
"filter",
|
||||
"temp",
|
||||
"tmp"
|
||||
],
|
||||
"license": "MIT",
|
||||
"name": "junk",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/sindresorhus/junk.git"
|
||||
},
|
||||
"scripts": {
|
||||
"test": "xo && ava"
|
||||
},
|
||||
"version": "1.0.3"
|
||||
}
|
46
node_modules/junk/readme.md
generated
vendored
Normal file
46
node_modules/junk/readme.md
generated
vendored
Normal file
@ -0,0 +1,46 @@
|
||||
# junk [](https://travis-ci.org/sindresorhus/junk)
|
||||
|
||||
> Filter out [OS junk files](test.js) like `.DS_Store` and `Thumbs.db`
|
||||
|
||||
|
||||
## Install
|
||||
|
||||
```sh
|
||||
$ npm install --save junk
|
||||
```
|
||||
|
||||
|
||||
## Usage
|
||||
|
||||
```js
|
||||
var fs = require('fs');
|
||||
var junk = require('junk');
|
||||
|
||||
fs.readdir('path', function (err, files) {
|
||||
console.log(files);
|
||||
//=> ['.DS_Store', 'test.jpg']
|
||||
|
||||
console.log(files.filter(junk.not));
|
||||
//=> ['test.jpg']
|
||||
});
|
||||
```
|
||||
|
||||
|
||||
## API
|
||||
|
||||
### junk.is(filename)
|
||||
|
||||
Returns true if `filename` matches a junk file.
|
||||
|
||||
### junk.not(filename)
|
||||
|
||||
Returns true if `filename` doesn't match a junk file.
|
||||
|
||||
### junk.re
|
||||
|
||||
The regex used for matching.
|
||||
|
||||
|
||||
## License
|
||||
|
||||
MIT © [Sindre Sorhus](http://sindresorhus.com)
|
Reference in New Issue
Block a user