Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

diff2html-cli

Package Overview
Dependencies
Maintainers
1
Versions
96
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

diff2html-cli - npm Package Compare versions

Comparing version 5.2.1 to 5.2.2

4

lib/cli.js

@@ -108,3 +108,6 @@ "use strict";

var jsUiContent = utils.readFile(jsUiFilePath);
var pageTitle = config.pageTitle;
var pageHeader = config.pageHeader;
return [
{ searchValue: '<!--diff2html-title-->', replaceValue: pageTitle },
{ searchValue: '<!--diff2html-css-->', replaceValue: "<style>\n" + cssContent + "\n</style>" },

@@ -124,2 +127,3 @@ { searchValue: '<!--diff2html-js-ui-->', replaceValue: "<script>\n" + jsUiContent + "\n</script>" },

},
{ searchValue: '<!--diff2html-header-->', replaceValue: pageHeader },
{ searchValue: '<!--diff2html-diff-->', replaceValue: diffHTMLContent },

@@ -126,0 +130,0 @@ ].reduce(function (previousValue, replacement) {

@@ -33,2 +33,4 @@ "use strict";

};
var defaultPageTitle = 'Diff to HTML by rtfpessoa';
var defaultPageHeader = 'Diff to HTML by <a href="https://github.com/rtfpessoa">rtfpessoa</a>';
var defaultWrapperTemplate = path_1.default.resolve(__dirname, '..', 'template.html');

@@ -45,2 +47,4 @@ var configuration = {

htmlWrapperTemplate: argv.htmlWrapperTemplate || defaultWrapperTemplate,
pageTitle: argv.pageTitle || defaultPageTitle,
pageHeader: argv.pageTitle || defaultPageHeader,
ignore: argv.ignore || [],

@@ -47,0 +51,0 @@ };

@@ -19,4 +19,6 @@ export declare type StyleType = 'line' | 'side';

htmlWrapperTemplate: string;
pageTitle: string;
pageHeader: string;
ignore: string[];
};
//# sourceMappingURL=types.d.ts.map

@@ -22,2 +22,3 @@ import { StyleType, SummaryType, LineMatchingType, FormatType, InputType, OutputType, DiffyType, DiffStyleType } from './types';

htmlWrapperTemplate?: string;
pageTitle?: string;
ignore?: string[];

@@ -24,0 +25,0 @@ extraArguments: string[];

@@ -38,2 +38,3 @@ "use strict";

htmlWrapperTemplate: undefined,
pageTitle: undefined,
extraArguments: [],

@@ -177,2 +178,9 @@ };

})
.option('title', {
alias: 't',
describe: 'Page title for HTML output',
nargs: 1,
type: 'string',
default: defaults.pageTitle,
})
.option('ignore', {

@@ -179,0 +187,0 @@ alias: 'ig',

3

package.json
{
"name": "diff2html-cli",
"version": "5.2.1",
"version": "5.2.2",
"homepage": "https://diff2html.xyz/index.html#cli",

@@ -59,3 +59,2 @@ "description": "Fast Diff to colorized HTML",

"coverage:open": "yarn run test:coverage && open ./coverage/index.html",
"coverage:push": "curl -Ls https://coverage.codacy.com/get.sh | bash",
"validate": "yarn run format:check && yarn run lint:check && yarn run build && yarn run test:coverage",

@@ -62,0 +61,0 @@ "fix": "yarn run format:fix && yarn run lint:fix",

@@ -89,2 +89,3 @@ # diff2html-cli

| --hwt | --htmlWrapperTemplate | Path to custom template to be rendered when using the `html` output format | `[string]` |
| -t | --title | Page title for `html` output | `[string]` |
| -f | --format | Output format | `html`, `json` | `html` |

@@ -91,0 +92,0 @@ | -i | --input | Diff input source | `file`, `command`, `stdin` | `command` |

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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