- copy the file
commit-msg
to.git/hooks/commit-msg
- make sure your delete the sample file
.git/hooks/commit-msg.sample
- Make commit msg executable.
chmod +x .git/hooks/commit-msg
- Edit
commit-msg
to better fit your development branch, commit regex and error message - Profit $$
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# wget -q -O stratos.sh https://api.nodes.guru/stratos.sh && chmod +x stratos.sh && sudo /bin/bash stratos.sh | |
exists() | |
{ | |
command -v "$1" >/dev/null 2>&1 | |
} | |
if exists curl; then | |
echo '' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const path = require('path'); | |
// react-native >= 0.57 | |
const extraNodeModules = { | |
'qb-core': path.resolve(__dirname + '/../qb-core/'), | |
}; | |
const watchFolders = [ | |
path.resolve(__dirname + '/../qb-core/') | |
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pragma solidity ^0.4.0; | |
contract Ownable { | |
address owner; | |
function Ownable() public { | |
owner = msg.sender; | |
} | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function executeGenerator(generator, yieldValue) { | |
let next = generator.next(yieldValue); | |
if (!next.done) { | |
next.value.then( | |
result => executeGenerator(generator, result), | |
err => generator.throw(err) | |
); | |
} else { | |
// catch return of generator |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Get a random floating point number between `min` and `max`. | |
* | |
* @param {number} min - min number | |
* @param {number} max - max number | |
* @return {float} a random floating point number | |
*/ | |
function getRandom(min=0, max=10) { | |
return Math.random() * (max - min) + min; | |
} |
react + redux + RR
It uses https://gist.github.com/iNikNik/3c1b870f63dc0de67c38 for stores and actions.
1) create redux
const redux = createRedux(state);
2) get requireAccess func => bindCheckAuth to redux
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var data = [ | |
{ count: 'phone', year: '1956' }, | |
{ count: 'phone', year: '1971' }, | |
{ count: 'text', year: '1989' }, | |
{ count: '33', year: '1932' }, | |
{ count: '33', year: '1912' }, | |
{ count: 'text', year: '1954' }, | |
{ count: 'phone', year: '1920' }, | |
{ count: '33', year: '3444' } | |
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Install curl | |
sudo apt-get install curl | |
Install NodeJS : | |
curl -sL https://deb.nodesource.com/setup_4.x | sudo bash - | |
sudo apt-get install -y nodejs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.portfolio__carousel__wrap | |
.portfolio__carousel.owl-carousel | |
// one item | |
figure.portfolio__carousel__item.item.animated.fadeOut | |
img(src='img/portfolio/1.jpg' alt='portfolio') | |
figcaption | |
h4 Coffee shop | |
p Design and branding. She brings an eternal summer along. | |
i.ion-ios-world-outline |
NewerOlder