3 ms·
You can use github and get namespacing under the author. IMO, this could end npmjs of they don't fix the issue.
by spinlock 11y ago
You can use github and get namespacing under the author.
IMO, this could end npmjs of they don't fix the issue.
- domoritz 11y agoAnd always use head? I think we still need versioning (potentially fuzzy). Also, isn't that what bower does/did?
- tdvorak 11y agoYou can provide any tag, sha, or branch which can be supplied as an argument to git checkout.
- jacobr 11y agoYou don't get any prepublish hook when pushing to a git repository though, so you can't do things like preprocess with babel, typescript, etc, unless you check in the compiled source.
- nostrademons 11y agoYou do, actually, if you've setup the git repository correctly. https://git-scm.com/book/en/v2/Customizing-Git-Git-Hooks https://git-scm.com/book/en/v2/Customizing-Git-Git-Hooks Check out the pre-push, pre-receive, update, and post-update hooks.
- jessaustin 11y agoThose hooks aren't tracked in the repo though, are they? In many cases that will be inconvenient.
- nostrademons 11y agoThey're placed in the repo itself, under .git/hooks, rather than in the working tree. If you want to version them, you can always place a symlink in .git/hooks and have it point to a file inside the working tree. Note that this won't work for bare repositories (which have no working tree), but usually in that case you want a separate deploy process where a sysadmin (or build script) manually copies over files, to prevent a random dev from borking the repository, which a bad update hook can easily do. (This doesn't help with the GitHub case. But then, as we saw from the recent CocoaPods story, using GitHub as your CDN is probably not a great idea either.)
- jessaustin 11y agoWell, sure, but that's complicated, and ".scripts.prepublish" in package.json is not. I'd love to have the git knowledge to do what you've described here without googling and frowning, but I don't have that yet, and I've been using git for years. Whereas I could use package.json to accomplish the same task on basically the first day I used npm.