Skip to content

Instantly share code, notes, and snippets.

View alispat's full-sized avatar
🎯
Focusing

Alisson Patrick alispat

🎯
Focusing
View GitHub Profile
@alispat
alispat / ExactMatchScriptUpdated.js
Created January 14, 2019 21:45 — forked from BrainlabsDigital/ExactMatchScriptUpdated.js
Create negatives where search queries are too dissimilar to the keywords they trigger. Based on containing the same words and/or edit distance.
/**
*
* Make Exact Match Exact
*
* Adds negatives for any search query that doesn't actually exactly match an exact
* match keyword.
*
* Version: 2.0
* Google AdWords Script maintained on brainlabsdigital.com
*
@alispat
alispat / Change in Campaign Spending Alert.js
Created January 14, 2019 21:46 — forked from BrainlabsDigital/Change in Campaign Spending Alert.js
Script to alert you if a campaign's spend has changed dramatically
/**
*
* Change in Campaign Spending Alert
*
* This script uses the current hour to calculate how much has been spent on
* individual campaigns on the day of running. The average spend up to the
* current hour in a specified numbers of days previously is averaged. If the
* spend today is higher by a specified percentage threshold an alert email
* is sent.
*
@alispat
alispat / Expanding Phrase Match Negatives.js
Created January 14, 2019 21:46 — forked from BrainlabsDigital/Expanding Phrase Match Negatives.js
Script to find potential negatives based on search queries that contain an existing phrase negative.
/**
*
* Expanding Phrase Match Negatives
*
* This script searches for all occurrences of phrase match negatives in search
* queries resulting from typos. Outputs a report to a Google Doc spreadsheet.
*
* Version: 1.0
* Google AdWords Script maintained on brainlabsdigital.com
*
@alispat
alispat / Low Quality Score Alert.js
Created January 14, 2019 21:49 — forked from BrainlabsDigital/Low Quality Score Alert.js
Script to email you if you have low quality score keywords, and optionally label/pause them
/**
*
* Low Quality Score Alert
*
* This script finds the low QS keywords (determined by a user defined threshold)
* and sends an email listing them. Optionally it also labels and/or pauses the
* keywords.
*
* Version: 1.0
* Google AdWords Script maintained on brainlabsdigital.com
@alispat
alispat / Pause Losing Ads.js
Created January 14, 2019 21:55 — forked from BrainlabsDigital/Pause Losing Ads.js
Script to find and label the best performing ads in each ad group, and label/pause the others.
/**
*
* Pause Losing Ads & Ad Rotate Analysis
*
* This script finds the best ad in each ad group (subject to thresholds) and
* calculates the performance you could have got if the impressions that went to
* losing ads went to the winning ads instead.
* Labels the winning and losing ads, and (optionally) pauses the losers.
*
* Version: 2.0
@alispat
alispat / Landing Page Contents Checker.js
Created January 14, 2019 21:58 — forked from BrainlabsDigital/Landing Page Contents Checker.js
Script to check landing pages for phrases like 'out of stock'
/**
*
* AdWords Script for checking the contents of landing pages.
* Goes to the final URL of keywords or ads, then searches the source code for
* user defined strings.
*
* Version: 1.0
* Google AdWords Script maintained by brainlabsdigital.com
*
**/
@alispat
alispat / Campaign Budget Overspend Monitoring
Created January 14, 2019 22:01 — forked from BrainlabsDigital/Campaign Budget Overspend Monitoring
Labels (and optionally pauses) campaigns that are overspending too much, and emails you a warning.
/**
*
* Campaign Budget Overspend Monitoring
*
* This script labels campaigns whose spend today is more than their daily
* budgets. Optionally, it also pauses campaigns whose spend exceeds the
* budget by too much. An email is then sent, listing the newly labelled
* and paused campaigns.
* When spend no longer exceeds budget, the campaigns are reactivated and
* labels are removed.
@alispat
alispat / bash_profile.md
Created April 8, 2019 12:58 — forked from ankurk91/bash_profile.md
:octocat: Git branch name in Linux/Mac Terminal

Mac OS : Show your git branch name on your terminal

Add these lines in your ~/.bash_profile file

# Show current git branch name
parse_git_branch() {
     git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ (\1)/'
}
export PS1="\u@\h \[\033[32m\]\w\[\033[33m\]\$(parse_git_branch)\[\033[00m\] $ "
{
"vars": {
"@gray-base": "#000",
"@gray-darker": "lighten(@gray-base, 10%)",
"@gray-dark": "lighten(@gray-base, 20%)",
"@gray": "lighten(@gray-base, 30%)",
"@gray-light": "lighten(@gray-base, 50%)",
"@gray-lighter": "lighten(@gray-base, 90%)",
"@brand-primary": "#337ab7",
"@brand-success": "#28B62C",

Nginx and Puma for Ruby on Rails

When a lot of people are working on the same Rails application, than Vagrant could help to set up environment quick and easy. Even Vagrant is not recommended for production, it is very usefull for testing deployment script. For production we can simply copy deployment script and run manually.

We can deploy Ruby on Rails app using a quick way to deploy ruby on rails on vagrant.