New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

imdone-core

Package Overview
Dependencies
Maintainers
1
Versions
484
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

imdone-core - npm Package Compare versions

Comparing version 1.2.15 to 1.2.16

14

.imdone/config.json

@@ -20,3 +20,3 @@ {

"name": "BACKLOG",
"hidden": false
"hidden": true
},

@@ -38,14 +38,2 @@ {

"hidden": true
},
{
"name": "doing",
"hidden": false
},
{
"name": "todo",
"hidden": false
},
{
"name": "publish",
"hidden": false
}

@@ -52,0 +40,0 @@ ],

2

lib/constants.js
'use strict';
var path = require('path');
// #DOING:0 Eliminate unused config options
// #DONE:0 Eliminate unused config options
var DEFAULT_EXCLUDE_PATTERN = "^(node_modules|bower_components|\\.imdone|target|build|dist|logs)[\\/\\\\]?|\\.(git|svn|hg|npmignore)|\\~$|\\.(jpg|png|gif|swp|ttf|otf)$";

@@ -6,0 +6,0 @@ var CONFIG_DIR = ".imdone";

@@ -252,3 +252,3 @@ 'use strict';

File.prototype.getLang = function() {
// #BACKLOG:10 Allow a project to extend languages by adding them to config.json git-iss:5
// #DONE:10 Allow a project to extend languages by adding them to config.json git-iss:5
var lang = this.languages[path.extname(this.path)];

@@ -272,17 +272,2 @@ return lang || {name:"text",symbol:""};

/**
* Description
* @method getCodeStyleRegex
* @return
*/
// #TODO:10 Remove this
File.prototype.getCodeStyleRegex = function() {
if (this.isCodeFile()) {
var symbol = this.getLang().symbol;
symbol.replace("/", "\\/");
var defactoPattern = "^(.*" + symbol + "\\s*)" + CODE_STYLE_PATTERN;
return new RegExp(defactoPattern, "mg");
}
};
File.prototype.newTask = function(list, text, order, line, type) {

@@ -412,5 +397,7 @@ var self = this;

// #DOING:10 This is not working on some files (Created in windows)
// #DOING:0 This is not working on some files (Created in windows)
File.getLineNumber = function(content, pos) {
var lines = content.split(/^/gm);
content = content.replace(/\r\n|\n\r|\r/g, "\n");
var re = /^/gm;
var lines = content.split(re);
var len = 0;

@@ -417,0 +404,0 @@ for (var i = 0; i < lines.length; i++) {

@@ -13,3 +13,2 @@ 'use strict';

languages = require('../languages'),
Minimatch = require('minimatch').Minimatch,
isBinaryFile = tools.isBinaryFile;

@@ -69,3 +68,3 @@ // recursive = require('recursive-readdir');

repo.loadIgnore = function() {
repo.ignores = [];
repo.globs = [];
var ignoreFile = _path.join(repo.path, constants.IGNORE_FILE);

@@ -75,4 +74,3 @@ if (!fs.existsSync(ignoreFile)) return;

if (glob === "") return;
var regex = (new Minimatch(glob)).makeRe();
repo.ignores.push(regex.source);
repo.globs.push(glob);
});

@@ -146,3 +144,3 @@ };

// #ARCHIVE:20 Fix loadConfig defaults
// #DOING:20 git-iss:2 assigned:piascikj If a config is bad move it to config.json.bak and save a new one with defaults +enhancement
// #DOING:10 git-iss:2 assigned:piascikj If a config is bad move it to config.json.bak and save a new one with defaults +enhancement
cb = tools.cb(cb);

@@ -250,8 +248,5 @@ repo.loadIgnore();

repo.readdir = function(path, all, callback) {
var ignores = repo.config.exclude || [];
ignores = (repo.ignores) ? _.uniq(ignores.concat(repo.ignores)) : ignores;
if (_.isFunction(all)) {
callback = all;
} else if (all) {
ignores = [];
all = false;
}

@@ -274,13 +269,9 @@

files.forEach(function (file) {
for (var i = 0; i < ignores.length; i++) {
var re = getRegExp(ignores[i]);
if (!re) return;
var relPath = repo.getRelativePath(p.join(path, file));
if (re.test(relPath)) {
pending -= 1;
if (pending <= 0) {
callback(null, list);
}
return;
var relPath = repo.getRelativePath(p.join(path, file));
if (!all && repo.shouldExclude(relPath)) {
pending -= 1;
if (pending <= 0) {
callback(null, list);
}
return;
}

@@ -287,0 +278,0 @@

@@ -10,2 +10,3 @@ 'use strict';

marked = require('marked'),
minimatch = require('minimatch'),
File = require('./file'),

@@ -408,2 +409,11 @@ Config = require('./config'),

}
if (this.globs) {
_.each(this.globs, function(pattern) {
if (minimatch(relPath, pattern)) {
exclude = true;
return false;
}
});
}
log("Exclude:%s | %s", relPath, exclude);

@@ -410,0 +420,0 @@

{
"name": "imdone-core",
"version": "1.2.15",
"version": "1.2.16",
"description": "imdone-core",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -68,6 +68,6 @@ imdone-core

- In code, tasks can be any style but must be in a line or block comment
- Code style tasks are only detected in comments for files with extensions listed in <a href="https://github.com/imdone/imdone-core/blob/master/lib/languages.js" target="_blank">imdone-core/languages.js</a> or the **languages** attribute in the `.imdone/config.json`
- Code style tasks are only detected in comments for files with extensions listed in [imdone-core/languages.js](https://github.com/imdone/imdone-core/blob/master/lib/languages.js) or the **languages** attribute in the `.imdone/config.json`
- When a code style task is moved, all code style tasks in affected lists are rewitten as hash style tasks
- For code and hash style tasks, the task text is terminated by the end of line
- Task text can have <a href="https://github.com/ginatrapani/todo.txt-cli/wiki/The-Todo.txt-Format" target="_blank">todo.txt formatting</a> but not todo.txt priority
- Task text can have [todo.txt formatting](https://github.com/ginatrapani/todo.txt-cli/wiki/The-Todo.txt-Format) but not todo.txt priority
- Task text can have markdown formatting

@@ -74,0 +74,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc