pazdera / gitwalk Goto Github PK
View Code? Open in Web Editor NEWBulk processing of git repositories
License: MIT License
Bulk processing of git repositories
License: MIT License
Hello,
Perhaps I've missed something, but can I create repositories using this? I'm looking for a bulk build script, but I cannot see one, and I figured if gitwalk could do it, it would be almost perfect! :)
Cheers.
A lovely tool. Sadly it works only with GitHub. Anyone who knows an alternative for GitLab or is able to update this tool?
I installed via npm install -g gitwalk
as directed, but running gitwalk produces
module.js:472
throw err;
^
Error: Cannot find module '../build/Debug/nodegit.node'
at Function.Module._resolveFilename (module.js:470:15)
at Function.Module._load (module.js:418:25)
at Module.require (module.js:498:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/home/adam/.npm-packages/lib/node_modules/gitwalk/node_modules/nodegit/lib/nodegit.js:16:12)
at Module._compile (module.js:571:32)
at Object.Module._extensions..js (module.js:580:10)
at Module.load (module.js:488:32)
at tryModuleLoad (module.js:447:12)
at Function.Module._load (module.js:439:3)
This seems to be the exact issue described by nodegit/nodegit#137, and to some extent nodegit/nodegit#521. According to a comment by @maxkorp, it seems that the nodegit folks were intending to make this error message less cryptic, but didn't get round to it yet. Anyway I found that I could fix this via:
cd ~/.npm-packages/lib/node_modules/gitwalk/node_modules/nodegit
npm install
This forced a build from source, and now it's working.
The README says:
You can match repositories on your file system using glob. Note that gitwalk will clone the repository
even if it's stored locally on your computer. One can never be too careful.
Sorry, but I strongly disagree ;-) Firstly, I'd suggest that this is too careful:
If there were no downsides to being careful, I'd concede that OK, no harm done. But unfortunately this approach has several big disadvantages to the user experience:
for
loop to work directly on the original repos, which defeats the point of gitwalk
.sed -i
) and then another one which reads (e.g. grep
) then the changes you just made vanish. This violates the Principle of Least Astonishment.If I've misunderstood, please correct me. But otherwise please consider changing the design of this. Thanks!
▶ npm install -g gitwalk
npm WARN deprecated [email protected]: 'github' has been renamed to '@octokit/rest' (https://git.io/vNB11)
npm WARN deprecated [email protected]: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
npm WARN deprecated [email protected]: CoffeeScript on NPM has moved to "coffeescript" (no hyphen)
/usr/local/bin/gitwalk -> /usr/local/lib/node_modules/gitwalk/out/bin/gitwalk.js
> [email protected] install /usr/local/lib/node_modules/gitwalk/node_modules/nodegit
> node lifecycleScripts/install
/usr/local/lib/node_modules/gitwalk/node_modules/promisify-node/utils/args.js:9
var args = func.toString().match(/function\s.*?\(([^)]*)\)/)[1];
^
TypeError: Cannot read property '1' of null
at module.exports (/usr/local/lib/node_modules/gitwalk/node_modules/promisify-node/utils/args.js:9:63)
at /usr/local/lib/node_modules/gitwalk/node_modules/promisify-node/index.js:79:29
at Array.filter (<anonymous>)
at processExports (/usr/local/lib/node_modules/gitwalk/node_modules/promisify-node/index.js:60:6)
at module.exports (/usr/local/lib/node_modules/gitwalk/node_modules/promisify-node/index.js:112:10)
at Object.<anonymous> (/usr/local/lib/node_modules/gitwalk/node_modules/nodegit/generate/scripts/generateNativeCode.js:3:13)
at Module._compile (internal/modules/cjs/loader.js:1133:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1153:10)
at Module.load (internal/modules/cjs/loader.js:977:32)
at Function.Module._load (internal/modules/cjs/loader.js:877:14)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.