alexpott / d8githooks Goto Github PK
View Code? Open in Web Editor NEWDrupal core committer git hooks
Drupal core committer git hooks
See https://gist.github.com/larowlan/d297f7c873d67c83985a143ba8c8799b
Can be ignored by adding to .git/info/exclude
There are a couple of things that get forgotten on commit a lot. Two in particular:
I'm not sure if a short reminder message on post-commit would be helpful or too spammy, but it's a thought.
In Drupal 9, some of the jQuery UI source files will be added to core/assets/vendor/jquery.ui
These source files can be minified into the files Drupal loads using a build script added in package.json: yarn build:jqueryui
or with yarn build
see: https://www.drupal.org/project/drupal/issues/3087685
@xjm suggested in #41 to add a check for the full build now that this directory will have source files and a build step in Drupal 9.
Add grep command to pre commit script to make sure there is no @todo left for this issue so when https://www.drupal.org/node/2577827 is fixed grep -inr 2577827 core/
should return nothing.
Running through all the instructions in the README, I get stuck at:
$ git commit -m "Test."
composer not installed, for instructions visit https://getcomposer.org/
And yet...
$ composer -V
Composer version 1.4.2 2017-05-17 08:17:52
Browsing through the code at https://github.com/alexpott/d8githooks/blob/master/pre-commit-8-4 this seems to result from the output of:
# Function to test for command dependencies.
command_exists () {
type "$1" &> /dev/null ;
}
If I manually type that from the command line, I get:
$ type "composer"
composer is aliased to `php /usr/local/bin/composer.phar'
Any ideas?
If we can somehow calculate which core dev branch we branched off of using some git commands, that'd be handy.
While the hooks run the eslint commands, there's following warnings:
warning From Yarn 1.0 onwards, scripts don't require "--" for options to be forwarded. In a future version, any explicit "--" will be forwarded as-is to the scripts.
Currently, the warning message is echoed but the commit proceeds. Exit with an non-zero exit code instead.
With https://www.drupal.org/node/2744463 in, use core's phpcs.
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.