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
find . -type d -name "node_modules" -exec touch "{}/.metadata_never_index" \; |
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
# file location: /etc/logrotate.d | |
/home/deploy/app/your-app/shared/log/*.log { | |
daily | |
missingok | |
rotate 14 | |
compress | |
delaycompress | |
dateext | |
notifempty |
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
require 'mina/rails' | |
require 'mina/git' | |
require 'mina/rvm' # for rvm support. (https://rvm.io) | |
require 'mina/puma' | |
# Basic settings: | |
# domain - The hostname to SSH to. | |
# deploy_to - Path to deploy into. | |
# repository - Git repo to clone from. (needed by mina/git) | |
# branch - Branch name to deploy. (needed by mina/git) |
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
functin formatMoney (value) { | |
if (!value) return '0'; | |
var num = value.toString().split('.')[0]; | |
var dot = value.toString().split('.')[1]; | |
var num = (num || 0).toString(), result = ''; | |
while (num.length > 3) { | |
result = ',' + num.slice(-3) + result; |