Support appending additional arguments
See original GitHub issueWould it be possible to add the ability to accept additional arguments so I could do something like this:
"husky": {
"hooks": {
"post-checkout": "yarnhook --ignore-optional",
"post-merge": "yarnhook --ignore-optional",
"post-rewrite": "yarnhook --ignore-optional"
}
}
I’d really like to prevent yarnhook from installing optional dependencies.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:3
- Comments:5 (4 by maintainers)
Top Results From Across the Web
Trying to use multiple arguments for .append, anyway how?
You are sending append() multiple arguments not a string. Format the argument as a string as such. Also, random.choice() is a better ...
Read more >Can .append(#1,#2) take two or more arguments - Codecademy
.append can does take two arguments, but one is an index and the other is what you want in that index. Remember, computers...
Read more >Append argument to arguments list - Unix Stack Exchange
Put the arguments into an array and then append to the array. args=("$@") args+=(foo) args+=(bar) baz "${args[@]}".
Read more >Python's .append(): Add Items to Your Lists in Place
Python lists reserve extra space for new items at the end of the list. A call to .append() will place new items in...
Read more >Function.prototype.apply() - JavaScript - MDN Web Docs
The apply() method calls the specified function with a given this value, and arguments provided as an array (or an array-like object).
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I don’t think this was a good idea. If someone wants to influence how the package manager is behaving itself, they can just create a config file for that package manager with settings. So if I want to skip optional dependencies, I would create a
.npmrc
with this content:Now because the CLI flags have the biggest priority, there is no way to include optional dependencies. I need optional dependencies to be installed. So now I have to always rerun
pnpm install
after switching branches. So yarnhook loses its benefits in my case.I cut a new release, it’s a major one due to the reasons mentioned in the release page. I hope this solves existing problems and please let me know if it breaks anything.