Skip to content

Instantly share code, notes, and snippets.

@Jeffrey903
Jeffrey903 / generate_qr_code.m
Created September 27, 2019 15:11
Generate QR code as UIImage
- (UIImage *)QRCodeImageOfSize:(CGFloat)size
{
NSString *string = @"https://google.com";
CIFilter *filter = [CIFilter filterWithName:@"CIQRCodeGenerator"];
[filter setDefaults];
[filter setValue:[string dataUsingEncoding:NSUTF8StringEncoding] forKey:@"inputMessage"];
[filter setValue:@"M" forKey:@"inputCorrectionLevel"];

Keybase proof

I hereby claim:

  • I am jeffrey903 on github.
  • I am jeffrey903 (https://keybase.io/jeffrey903) on keybase.
  • I have a public key ASDfvcq5dZmd0PjVlOqkY6bWFbsnCF9fmgu9CjDwI8QIEgo

To claim this, I am signing this object:

@Jeffrey903
Jeffrey903 / steve_jobs_remembrances.py
Created October 19, 2011 15:19
Download all of the Steve Jobs remembrances on Apple's website
#!/usr/bin/python
#
# Download all of the Steve Jobs remembrances on Apple's website
# Will output to standard out
#
# Usage: python steve_jobs_remembrances.py > steve_jobs_remembrances.mdown
# to save to a file
#
# At the time of writing this script, there were 5000 messages totaling ~1.5MB
#