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
//this file is an example of using leader + t to runn the current spec in vs code. | |
// you need two extentions: | |
// vim-mode | |
// rails run specs | |
// once those are installed add this to the config: | |
{ | |
"vim.normalModeKeyBindingsNonRecursive": [ | |
{ | |
"before": ["<leader>", "T"], | |
"commands": ["extension.runFileSpecs"] |
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
/* eslint-env node */ | |
var EmberApp = require('ember-cli/lib/broccoli/ember-app'); | |
var ENV = { | |
browsers: [ | |
'last 1 Chrome versions', | |
'last 1 Firefox versions' | |
] | |
}; |
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
RSpec.configure do |config| | |
config.filter_run :focus => true | |
config.run_all_when_everything_filtered = true | |
end |
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
http://www.htaccesstools.com/htaccess-authentication/ | |
AuthType Basic | |
AuthName "staging" | |
AuthUserFile /home/content/84/10444784/html/staging/.htpasswd | |
Require valid-user | |
<?php | |
$dir = dirname(__FILE__); |
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
<?php // adding the product and helper objects in magento | |
$_helper = $this->helper('catalog/output'); | |
$_product = $this->getProduct(); | |
// getting a product from the what was registered on the page | |
$_product = Mage::registry('product'); |
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
mySQL dump: | |
backup: # | |
mysqldump -u root -p[root_password] [database_name] > dumpfilename.sql | |
restore:# | |
mysql -u root -p[root_password] [database_name] < dumpfilename.sql | |
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
<script> | |
function myRegistryValidate(){ | |
var formToValidate = $('Insert Magento Form ID'); | |
var validator = new Validation(formToValidate); | |
if(validator.validate()) { | |
//Do Stuffs | |
} | |
} | |
</script> |
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
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
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
NameVirtualHost * | |
<VirtualHost *> | |
DocumentRoot "/Applications/MAMP/htdocs" | |
ServerName localhost | |
</VirtualHost> | |
<VirtualHost *> | |
DocumentRoot "/Applications/MAMP/htdocs/magento" | |
ServerName magento.dev |
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 "rails_helper" | |
RSpec.describe CampaignMailingTemplate, type: :template_object do | |
before(:all) do | |
# old factory girl code | |
# @entity = create(:entity) | |
# @campaign = create(:campaign, entity: @entity) | |
# @campaign_mailing = create(:campaign_manual_reminder, campaign: @campaign) | |
# @invitation = build(:invitation, guest: build(:user)) | |
create_entity |
NewerOlder