Skip to content

Commit

Permalink
Update diff2html and add style configurations
Browse files Browse the repository at this point in the history
  • Loading branch information
rtfpessoa committed May 6, 2016
1 parent 85f833d commit 22f2cb5
Show file tree
Hide file tree
Showing 7 changed files with 52 additions and 35 deletions.
16 changes: 16 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# This file is for unifying the coding style for different editors and IDEs
# editorconfig.org

root = true

[*]
end_of_line = lf
charset = utf-8
insert_final_newline = true
trim_trailing_whitespace = true
indent_style = space
indent_size = 2
max_line_length = 120

[Makefile]
indent_style = tab
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,6 @@ target/
# Node
node_modules/
npm-debug.log

# Istanbul
coverage/
1 change: 0 additions & 1 deletion .jscsrc
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
"disallowTrailingWhitespace": true,
"maximumLineLength": 130,
"requireCamelCaseOrUpperCaseIdentifiers": true,
"requireCapitalizedComments": true,
"requireCapitalizedConstructors": true,
"requireSpaceAfterKeywords": [
"if",
Expand Down
3 changes: 1 addition & 2 deletions circle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,5 @@ test:
- nvm install 5 && npm test
post:
- npm install
- istanbul cover ./node_modules/mocha/bin/_mocha --report lcovonly -- -R spec
- npm test
- cat ./coverage/lcov.info | ./node_modules/.bin/codacy-coverage
- rm -rf ./coverage
40 changes: 20 additions & 20 deletions dist/template.html
Original file line number Diff line number Diff line change
@@ -1,38 +1,38 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Diff to HTML by rtfpessoa</title>
<meta charset="utf-8">
<title>Diff to HTML by rtfpessoa</title>

<!--
Diff to HTML (template.html)
Author: rtfpessoa
-->
<!--
Diff to HTML (template.html)
Author: rtfpessoa
-->

<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.1.0/styles/github.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.3.0/styles/github.min.css">

<!--diff2html-css-->
<!--diff2html-css-->

<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.2.0/jquery.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/2.2.3/jquery.js"></script>

<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.1.0/highlight.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.1.0/languages/scala.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.3.0/highlight.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.3.0/languages/scala.min.js"></script>

<!--diff2html-js-ui-->
<!--diff2html-js-ui-->

<script>
$(document).ready(function() {
var diff2htmlUi = new Diff2HtmlUI();
//diff2html-fileListCloseable
diff2htmlUi.highlightCode('#diff');
});
</script>
<script>
$(document).ready(function() {
var diff2htmlUi = new Diff2HtmlUI();
//diff2html-fileListCloseable
diff2htmlUi.highlightCode('#diff');
});
</script>
</head>
<body style="text-align: center; font-family: 'Source Sans Pro',sans-serif;">
<h1>Diff to HTML by <a href="https://github.com/rtfpessoa">rtfpessoa</a></h1>

<div id="diff">
<!--diff2html-diff-->
<!--diff2html-diff-->
</div>
</body>
</html>
22 changes: 11 additions & 11 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "diff2html-cli",
"version": "1.4.6-beta4",
"version": "1.4.6-beta6",
"homepage": "https://www.github.com/rtfpessoa/diff2html-cli",
"description": "Fast Diff to colorized HTML",
"keywords": [
Expand Down Expand Up @@ -34,28 +34,28 @@
"engines": {
"node": ">=0.12.0"
},
"preferGlobal": "true",
"preferGlobal": true,
"scripts": {
"test": "mocha",
"style": "jscs src test",
"codacy": "istanbul cover ./node_modules/mocha/bin/_mocha --report lcovonly -- -R spec && cat ./coverage/lcov.info | ./node_modules/.bin/codacy-coverage && rm -rf ./coverage"
"test": "jscs src/*.js && istanbul cover _mocha -- -u exports -R spec ./test/**/*",
"style": "jscs src/*.js",
"codacy": "istanbul cover _mocha -- -u exports -R spec ./test/**/* && cat ./coverage/lcov.info | codacy-coverage"
},
"bin": {
"diff2html": "./bin/diff2html"
},
"main": "./src/main.js",
"dependencies": {
"copy-paste": "^1.1.4",
"diff2html": "^2.0.0-beta10",
"copy-paste": "^1.2.0",
"diff2html": "^2.0.0-beta18",
"extend": "^3.0.0",
"open": "0.0.5",
"request": "^2.69.0",
"yargs": "^4.3.2"
"request": "^2.72.0",
"yargs": "^4.7.0"
},
"devDependencies": {
"codacy-coverage": "^1.1.3",
"istanbul": "^0.4.2",
"jscs": "^2.11.0",
"istanbul": "^0.4.3",
"jscs": "^3.0.3",
"mocha": "^2.4.5"
},
"license": "MIT",
Expand Down
2 changes: 1 addition & 1 deletion src/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ var argv = yargs.usage('Usage: diff2html [options] -- [diff args]')
})
.help('h')
.alias('h', 'help')
.epilog('© 2014 rtfpessoa\n' +
.epilog('© 2014-2016 rtfpessoa\n' +
'For support, check out https://github.com/rtfpessoa/diff2html-cli')
.argv;

Expand Down

0 comments on commit 22f2cb5

Please sign in to comment.