Skip to content

Instantly share code, notes, and snippets.


Rishabh Tayal RishabhTayal

View GitHub Profile
View Fastfile
platform :ios do
desc "\033[1mDeploy PersonalShopper to iTunes Connect\033[0m"
desc "This action does the following:"
desc "- Post the message on Slack"
desc "- Input version number from user"
desc "- Increament version number"
desc "- Increament build number"
desc "- Generate build"
desc "- Push the changed plist to git remote"
View fastlane-template
default_platform :ios
platform :ios do
before_all do
# ENV["SLACK_URL"] = ""
# ENV['DEVELOPER_DIR'] = '/Applications/Xcode old/'
View data.json
RishabhTayal / dynamic_text.json
Created Sep 1, 2017
Lottie animation json for simple text animation
View dynamic_text.json
RishabhTayal / 106 ms.swift
Last active Aug 15, 2017
!Takes 106ms to compile!
View 106 ms.swift
class func animateLeftToRight(_ view: SpringLabel) {
view.animation = "fadeInRight"
view.duration = 2.0
view.force = 0.4
view.velocity = 0.3
view.damping = 1
view.curve = "easeIn"
View git

Delete all local branches

git branch | grep -v "master" | xargs git branch -D

View Swift 3 Migration

Swift 3 Changes

1. Simpler APIs, Omit unneccessary words.


let blue = UIColor.blueColor()
View ccache -s output
cache directory /Users/rtayal/.ccache
primary config /Users/rtayal/.ccache/ccache.conf
secondary config (readonly) /usr/local/Cellar/ccache/3.3.3/etc/ccache.conf
cache hit (direct) 0
cache hit (preprocessed) 0
cache miss 0
cache hit rate 0.00 %
called for link 5
unsupported compiler option 9
no input file 3
View URL meta tags parsing (WIP)
let urlString = ""
let photoData = NSMutableData(contentsOfURL: NSURL(string: urlString)!)
let dataString = String(data: photoData!, encoding: NSUTF8StringEncoding)
do {
// <meta property=\"og:image
let regex = try NSRegularExpression(pattern: "<meta.*property=\"og:image\".*content=\"(.*)\".*\\/>", options: .CaseInsensitive)
RishabhTayal / Xcode
Last active May 16, 2016
List of useful Xcode plugins.
View Xcode