Skip to content

Instantly share code, notes, and snippets.

Raul Brito raulbrito

Block or report user

Report or block raulbrito

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
raulbrito /
Created Jan 28, 2016
Update repository with latest changes from the Shopify side
git status # make sure you don't have any changes locally
theme download # get the latest version from the shopify servers
git add . # adds all the changed files to be commited
git commit -m "commit changes from server" # commits all changes made since last time
git push origin master # pushes the changes to the remote repository
raulbrito /
Created Jan 28, 2016
Add commit to repo with latest changes
git status # allows to see the changes made
git add . # to add all the changed files. you can also add them one by one
git commit -m "description of changes made" # commits the changes locally
git push origin master # or any other remote repository and branch to you prefer
theme configure f3d64ec79d0d8339d745208bf382bd85 2526f780336b9284ee980d630c36bc2f 84991510 # this create a configuration file (config.yml)
theme download # this downloads all the corresponding theme files to your computer
git init . # this creates a local git repository
git add . && git commit -m "first commit" # adds all the files to the local repository
View shopify-tracker.rb
require 'pusher-client'
require 'sqlite3'
require 'json'
db = "blackfriday.db"
#rows = db.execute <<-SQL
# create table orders (
# from_latitude int,
# from_longitude int,
raulbrito / theme.liquid
Last active Aug 29, 2015
VAT rates for Shopify - multiple variants
View theme.liquid
<!-- make sure to apply the changes for the single variant approach
before making these changes for multi-variant.
Single variant approach is implemented here:
var selectCallback = function(variant, selector) {
if (variant) {
if (variant.featured_image) {
var newImage = variant.featured_image;
raulbrito / cart.liquid
Last active Aug 29, 2015
VAT rates for Shopify - single variant
View cart.liquid
{% for item in cart.items %}
<td class="image">
<div class="product_image">
<a href="{{ item.url }}">
<img src="{{ item | img_url: 'small' }}" alt="{{ item.title | escape }}" />
View eclipse.ini
C:/JDK7/jre/bin/server/jvm.dll #Windows
#/Library/Java/JavaVirtualMachines/jdk1.7.0_25.jdk/Contents/Home/bin/java #OS X
-Xss1m LastName
View gist:791330
$ sudo gem install rack
$ sudo gem install sinatra
$ sudo gem install shotgun
package ca.jbrains.pos.test;
import static org.junit.Assert.*;
import java.util.*;
import org.junit.*;
public class SellOneItemTest {
public static class Sale {
package calculator;
public class CalculatorController {
private final CalculatorModel model;
private Calculation calculation;
public CalculatorController(CalculatorModel model, Calculation calculation) {
this.model = model;
You can’t perform that action at this time.