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
# Prepare branch | |
cd repository | |
git checkout --orphan <orphan-name> | |
git rm -rf . | |
rm '.gitignore' | |
# Create a commit (this can be empty) and push | |
git commit --allow-empty -m “root commit” | |
git push origin orphan_name |
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
import UIKit | |
extension UIImage { | |
subscript (x: Int, y: Int) -> UIColor? { | |
if x < 0 || x > Int(size.width) || y < 0 || y > Int(size.height) { | |
return nil | |
} |