Skip to content

Instantly share code, notes, and snippets.

@chml
chml / Xcode build number
Last active January 18, 2022 00:06
Using git commit count as Xcode build number
#
# https://gist.github.com/johankool/c33cffc0727b13f22f25
# Set the build number to the current git commit count.
# If we're using the Dev scheme, then we'll suffix the build
# number with the current branch name, to make collisions
# far less likely across feature branches.
# Based on:
# http://w3facility.info/question/how-do-i-force-xcode-to-rebuild-the-info-plist-file-in-my-project-every-time-i-build-the-project/
# http://blog.jaredsinclair.com/post/97193356620/the-best-of-all-possible-xcode-automated-build#fnref:p97193356620-1
#
@tangqiaoboy
tangqiaoboy / UIView+frameAdjust.h
Last active March 25, 2020 04:18
Adjust UIView frame category
//
// UIView+frameAdjust.h
// fenbi
//
// Created by Tang Qiao on 12-5-31.
// Copyright (c) 2012年 Fenbi.com . All rights reserved.
//
#import <Foundation/Foundation.h>
@maciekish
maciekish / NSObject+Association.h
Created December 3, 2013 16:49
Ever dreamed of adding "userInfo" to an UIAlertView? Now you can! This category allows you to assign any object to any object from iOS 3.1 and Mac OS 10.6 and up.
//
// NSObject+Association.h
//
// Created by Maciej Swic on 03/12/13.
// Released under the MIT license.
//
#import <Foundation/Foundation.h>
@interface NSObject (Association)
@bobmoff
bobmoff / UIView+RoundedCorners.h
Created July 10, 2013 15:23
Add rounded corners to any view using layer mask.
#import <UIKit/UIKit.h>
@interface UIView (RoundedCorners)
- (void)setRoundedCorners:(UIRectCorner)corners radius:(CGSize)size;
@end