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

git-log-utils

Package Overview
Dependencies
Maintainers
1
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

git-log-utils - npm Package Compare versions

Comparing version 0.2.0 to 0.2.1

6

CHANGELOG.md

@@ -0,1 +1,7 @@

## [0.2.1](https://github.com/littlebee/git-log-utils.git/compare/0.2.0...0.2.1) (2016-03-89)
### Other Commits
* [c7dc6eb](https://github.com/littlebee/git-log-utils.git/commit/c7dc6eb469ebca55124ad7f12c696a130d6fe76d) fixes git-time-machine:issue#30. should handle spaces in directory and file names and properly escape and normalize file for windows
## [0.2.0](https://github.com/littlebee/git-log-utils.git/compare/0.1.6...0.2.0) (2016-03-87)

@@ -2,0 +8,0 @@ Thank you @Faleij the critical windows fix. Did I ever tell you, you're my hero. :)

20

lib/git-log-utils.js

@@ -52,5 +52,6 @@ // Generated by CoffeeScript 1.9.3

} else {
directory = Path.normalize(Path.dirname(fileName));
directory = Path.dirname(fileName);
}
cmd = "cd " + directory + " && git log" + flags + " " + fileName;
fileName = Path.normalize(this._escapeSpacesInPath(fileName));
cmd = "git log" + flags + " " + fileName;
if (process.env.DEBUG === '1') {

@@ -60,3 +61,4 @@ console.log('$ ' + cmd);

return ChildProcess.execSync(cmd, {
stdio: 'pipe'
stdio: 'pipe',
cwd: directory
}).toString();

@@ -106,2 +108,14 @@ };

/*
See nodejs Path.normalize(). This method extends Path.normalize() to add:
- escape of space characters
*/
GitLogUtils._escapeSpacesInPath = function(filePath) {
var spaceReplacement;
spaceReplacement = process.platform === 'win32' ? '^ ' : '\\ ';
return filePath.replace(/ /g, spaceReplacement);
};
return GitLogUtils;

@@ -108,0 +122,0 @@

2

package.json
{
"name": "git-log-utils",
"version": "0.2.0",
"version": "0.2.1",
"description": "Utility methods for parsing git log output",

@@ -5,0 +5,0 @@ "main": "lib/git-log-utils.js",

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