-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
1,679 additions
and
1,443 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,24 +9,24 @@ var getStdin = _interopDefault(require('get-stdin')); | |
var updateNotifier = _interopDefault(require('update-notifier')); | ||
var commonTags = require('common-tags'); | ||
var string = require('@thebespokepixel/string'); | ||
var trucolor = require('trucolor'); | ||
var deepAssign = _interopDefault(require('deep-assign')); | ||
var terminalFeatures = _interopDefault(require('term-ng')); | ||
var columnify = _interopDefault(require('columnify')); | ||
var osLocale = _interopDefault(require('os-locale')); | ||
var verbosity = require('verbosity'); | ||
var meta = _interopDefault(require('@thebespokepixel/meta')); | ||
var nSelector = require('@thebespokepixel/n-selector'); | ||
var ansiRegex = _interopDefault(require('ansi-regex')); | ||
var trucolor = require('trucolor'); | ||
var deepAssign = _interopDefault(require('deep-assign')); | ||
var fs = require('fs'); | ||
var path = require('path'); | ||
var _min = _interopDefault(require('lodash/min')); | ||
var _max = _interopDefault(require('lodash/max')); | ||
var _split = _interopDefault(require('lodash/split')); | ||
var _forEach = _interopDefault(require('lodash/forEach')); | ||
var terminalFeatures = _interopDefault(require('term-ng')); | ||
|
||
const name = "truwrap"; | ||
const version = "1.0.3"; | ||
const version = "1.0.4"; | ||
const description = "Smarter terminal text wrapping (handles 24bit color)"; | ||
const author = "Mark Griffiths <[email protected]> (http://thebespokepixel.com/)"; | ||
const main = "index.js"; | ||
|
@@ -40,7 +40,7 @@ const files = [ | |
"bin/" | ||
]; | ||
const bugs = { | ||
url: "https://github.com/MarkGriffiths/truwrap/issues" | ||
url: "https://github.com/thebespokepixel/truwrap/issues" | ||
}; | ||
const copyright = { | ||
year: "2019", | ||
|
@@ -56,47 +56,47 @@ const scripts = { | |
coverage: "nyc ava && nyc report --reporter=lcov --report-dir test/coverage; open test/coverage/lcov-report/index.html" | ||
}; | ||
const devDependencies = { | ||
"@babel/core": "^7.4.5", | ||
"@babel/preset-env": "^7.4.5", | ||
ava: "^2.1.0", | ||
"@babel/core": "^7.5.5", | ||
"@babel/preset-env": "^7.5.5", | ||
ava: "^2.2.0", | ||
"babel-plugin-lodash": "^3.3.4", | ||
"documentation-theme-bespoke": "^0.5.6", | ||
gulp: "^4.0.2", | ||
"gulp-better-rollup": "^4.0.1", | ||
"gulp-chmod": "^3.0.0", | ||
"gulp-rename": "^1.4.0", | ||
nyc: "^14.1.1", | ||
rollup: "^1.15.3", | ||
"rollup-plugin-babel": "^4.3.2", | ||
"rollup-plugin-commonjs": "^10.0.0", | ||
rollup: "^1.19.4", | ||
"rollup-plugin-babel": "^4.3.3", | ||
"rollup-plugin-commonjs": "^10.0.2", | ||
"rollup-plugin-json": "^4.0.0", | ||
"rollup-plugin-node-resolve": "^5.0.2", | ||
"rollup-plugin-node-resolve": "^5.2.0", | ||
"semver-regex": "^3.1.0", | ||
xo: "^0.24.0" | ||
}; | ||
const dependencies = { | ||
"@thebespokepixel/meta": "^1.0.3", | ||
"@thebespokepixel/n-selector": "^1.0.3", | ||
"@thebespokepixel/string": "^0.5.7", | ||
"@thebespokepixel/meta": "^1.0.4", | ||
"@thebespokepixel/n-selector": "^1.0.4", | ||
"@thebespokepixel/string": "^0.5.8", | ||
"ansi-regex": "^4.1.0", | ||
columnify: "^1.5.4", | ||
"common-tags": "^1.8.0", | ||
"deep-assign": "^3.0.0", | ||
"es6-promisify": "^6.0.1", | ||
"get-stdin": "^7.0.0", | ||
lodash: "^4.17.11", | ||
lodash: "^4.17.15", | ||
"os-locale": "^4.0.0", | ||
"read-pkg-up": "^6.0.0", | ||
"term-ng": "^1.0.3", | ||
"term-ng": "^1.0.4", | ||
trucolor: "^1.0.3", | ||
"update-notifier": "^3.0.0", | ||
verbosity: "^1.1.1", | ||
yargs: "^13.2.4" | ||
"update-notifier": "^3.0.1", | ||
verbosity: "^1.1.2", | ||
yargs: "^13.3.0" | ||
}; | ||
const engines = { | ||
node: ">=8.0" | ||
}; | ||
const homepage = "https://github.com/MarkGriffiths/truwrap"; | ||
const homepage = "https://github.com/thebespokepixel/truwrap"; | ||
const keywords = [ | ||
"text", | ||
"wrap", | ||
|
@@ -111,7 +111,7 @@ const keywords = [ | |
const license = "MIT"; | ||
const repository = { | ||
type: "git", | ||
url: "git+https://github.com/MarkGriffiths/truwrap.git" | ||
url: "git+https://github.com/thebespokepixel/truwrap.git" | ||
}; | ||
const xo = { | ||
semicolon: false, | ||
|
@@ -125,16 +125,16 @@ const xo = { | |
] | ||
}; | ||
const badges = { | ||
github: "MarkGriffiths", | ||
github: "thebespokepixel", | ||
npm: "thebespokepixel", | ||
name: "truwrap", | ||
codeclimate: "e03a2055456023267873", | ||
codeclimate: "5732d1aad01d74b6ef4a", | ||
providers: { | ||
aux1: { | ||
title: "github", | ||
text: "source", | ||
color: "4E73B6", | ||
link: "https://github.com/MarkGriffiths/truwrap" | ||
link: "https://github.com/thebespokepixel/truwrap" | ||
} | ||
}, | ||
readme: { | ||
|
@@ -156,8 +156,7 @@ const badges = { | |
"rollup" | ||
], | ||
Help: [ | ||
"inch", | ||
"gitter" | ||
"inch" | ||
] | ||
}, | ||
docs: [ | ||
|
@@ -197,6 +196,16 @@ var pkg = { | |
badges: badges | ||
}; | ||
|
||
const clr = deepAssign(trucolor.simple({ | ||
format: 'sgr' | ||
}), trucolor.palette({ | ||
format: 'sgr' | ||
}, { | ||
bright: 'bold rgb(255,255,255)', | ||
dark: '#333' | ||
})); | ||
const colorReplacer = new commonTags.TemplateTag(commonTags.replaceSubstitutionTransformer(/([a-zA-Z]+?)[:/|](.+)/, (match, colorName, content) => `${clr[colorName]}${content}${clr[colorName].out}`)); | ||
|
||
const tabRegex = /\t/g; | ||
const newlineRegex = /\n/g; | ||
|
||
|
@@ -349,16 +358,6 @@ class WrapTool { | |
|
||
var createWrapTool = (options => new WrapTool(options)); | ||
|
||
const clr = deepAssign(trucolor.simple({ | ||
format: 'sgr' | ||
}), trucolor.palette({ | ||
format: 'sgr' | ||
}, { | ||
bright: 'bold rgb(255,255,255)', | ||
dark: '#333' | ||
})); | ||
const colorReplacer = new commonTags.TemplateTag(commonTags.replaceSubstitutionTransformer(/([a-zA-Z]+?)[:/|](.+)/, (match, colorName, content) => `${clr[colorName]}${content}${clr[colorName].out}`)); | ||
|
||
const prefix = '\u001B]1337;File=inline=1;'; | ||
const suffix = '\u0007'; | ||
const broken = `${__dirname}/../media/broken.png`; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.