This file contains hidden or 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
| # Taking from this blogPost: https://medium.com/@tjkangs/travisci-circleci-2-0-with-fastlane-for-react-native-both-ios-and-android-3f99b71b8691 | |
| aliases: | |
| # Cache Management | |
| - &restore-yarn-cache | |
| keys: | |
| - yarn-{{ arch }}-{{ .Branch }}-{{ checksum "package.json" }} | |
| # Fallback in case checksum fails | |
| - yarn-{{ arch }}-{{ .Branch }}- | |
| # Fallback in case this is a first-time run on a fork |
This file contains hidden or 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/sh | |
| brew install nodenv yarn | |
| nodenv install 6.7.0 | |
| nodenv rehash | |
| nodenv global 6.7.0 | |
| echo 'export PATH="$HOME/.nodenv/bin:$PATH"' >> ~/.bash_profile | |
| echo 'eval "$(nodenv init -)"' >> ~/.bash_profile | |
| source ~/.bash_profile |
This file contains hidden or 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 'rubygems' | |
| require 'httparty' | |
| resp = HTTParty.get("http://www.catfact.info//api/v1/facts.json?page=1&per_page=30") | |
| resp['facts'].each do |item| | |
| puts item.inspect | |
| end |
This file contains hidden or 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
| class OmniauthCallbacksController < Devise::OmniauthCallbacksController | |
| def twitter | |
| handle_redirect('devise.twitter_uid', 'Twitter') | |
| end | |
| def facebook | |
| handle_redirect('devise.facebook_data', 'Facebook') | |
| end | |
| private |
This file contains hidden or 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
| GMaps = function(options){ | |
| this.div = $(options.div)[0]; | |
| this.markers = []; | |
| this.polygon = null; | |
| this.infoWindow = null; | |
| this.map = new google.maps.Map(this.div, { | |
| zoom: 15, | |
| center: new google.maps.LatLng(options.lat, options.lng), | |
| mapTypeId: google.maps.MapTypeId.ROADMAP | |
| }); |